IO Config Editor
NOTICE: This page consists of information on a feature currently in Beta. Information is liable to change or be incomplete.
The Input/Output (IO) Configuration Editor page is the page where you can edit the physical IO configuration of the RoboPad board by configuring IO Units. You can, for instance, set one of the external pins to output a digital electronic signal, which can be controlled via the nodegraph. It is accessible via the Management Page.
Each IO Unit has a number of settings and will add it's own input and output ports to the Chip Node in the nodegraph. Importantly, for actuators, you are able to specify safe values - these are the values that the IO Unit will default to when the RoboPad looses connection to your phone or you are on any screen other than the controller screen (it's emergency stop state). It is very important that you understand how your safe values and IO Units in general interact with the physical circuitry you have added to your RoboPad - for instance, if you are adding an additional motor to your robot using a Generic PWM IO Unit, you will most likely want to ensure that it's safe value is set to 0 so that it will turn off in an emergency situation. Some IO Units do not have safe value settings (such as HBridge motors and unidirectional brushless motors) as all of these configurations are configured to turn off by default.
Changing the physical configuration of the RoboPad and the behaviour of it's pins using the IO Configuration Editor should be considered an advanced topic - ensure that you have read and fully understand everything on this wiki page and everything you are doing before attempting to change these settings.
Emergency Stop Behaviour When Changing IO Unit Configuration
It is also important to understand that IO Unit safe values remain configured on the pins they are set to, even when removed (using the red "x") until either another IO Unit is configured to use that pin or the device is reset. This has been done because it is not recommended, expected or suggested that a user would change the physical configuration of their RoboPad circuit without first powering it down. Therefore, the firmware assumes that the safest thing to do is retain the last set safe value for any given pin until it is told otherwise (or the device is power cycled, at which point unconfigured pins remain at a high-impedance state).
"Advanced Pins"
Some Pins - namely all pins that are not External 1 and External 2 (marked E1 and E2 respectively on the board) are considered Advanced Pins. This is because they may behave in a way outside of expected behaviour. For instance, many of these pins will output arbitrary signals within the first 500 milliseconds of RoboPad boot and as such should not be used for actuators that may cause harm if they were to unexpectedly move. Others (particularly the "Internal" pins) are already connected to some internal electronics on the RoboPad, such as the built-in HBridge that drives the default M1 and M2 outputs. In order to use these pins, you would have to remove the HBridge from the device (which is not advised and will void the product's guarantee).
Pins
All pins are capable of driving a small current at 3.3v to external circuitry, below is a list of the different pin names and how they might be used.
Pin Name | ID on Board | Information |
---|---|---|
External 1 | E1 | Non-advanced pin. |
External 2 | E2 | Non-advanced pin. |
TX | T | The "Transmit" pin when manually reprogramming the RoboPad.
Subject to pseudo-random signal state for the first 500ms after RoboPad boot. |
RX | R | The "Recieve" pin when manually reprogramming the RoboPad.
Subject to pseudo-random signal state for the first 500ms after RoboPad boot. |
Safeboot | SB | Pulled low through an on-board 10kΩ resistor, and meant to be connected to the 3.3v pin (pulling it high) at the 4 seconds after boot point to enable safeboot.
Subject to pseudo-random signal state for the first 500ms after RoboPad boot. |
Program Enable | PE | Used along with the TX and RX pins to manually reprogram the RoboPad.
Subject to pseudo-random signal state for the first 500ms after RoboPad boot. |
Unset | When "Unset" is available, the pin may optionally be non-configured. Choosing this option means no pin is used for the particular option. | |
Drive Enable | Internal | An internal pin used to enable or disable the built-in HBridge chip.
Subject to pseudo-random signal state for the first 500ms after RoboPad boot. |
Drive Pin 1
Forward |
Internal | An internal pin attached to the built-in HBridge chip.
Subject to pseudo-random signal state for the first 500ms after RoboPad boot. |
Drive Pin 1
Backward |
Internal | An internal pin attached to the built-in HBridge chip.
Subject to pseudo-random signal state for the first 500ms after RoboPad boot. |
Drive Pin 2
Forward |
Internal | An internal pin attached to the built-in HBridge chip.
Subject to pseudo-random signal state for the first 500ms after RoboPad boot. |
Drive Pin 2
Backward |
Internal | An internal pin attached to the built-in HBridge chip.
Subject to pseudo-random signal state for the first 500ms after RoboPad boot. |
IO Units
A variety of IO Units can be added that are suitable for a number of uses, all are listed here.
Actuators
All actuators add input ports to the Chip Node, allowing signals to be passed from the Node Graph to each actuator. On top of this, each actuator will create an output port on the Chip Node, usually labelled ending with "Armed" - this is an indicator of whether or not the actuator is armed. The signal to any specific actuator must pass through that actuator's configured safe value for it to be considered to be armed - then and only then will the actuator start to process new control signals. As an example, an servo attached using the "PWM Output" with a safety value set to 50% would require a near-50% signal to be sent to it's input before you will be able to see any change in the pin's output.
All actuators output 3.3 volts along their output pins. Make sure that any connected peripherals such as ESCs or H-Bridges operate with 3.3 volt logic.
H-Bridge Motor
A H-Bridge is a simple, common circuit that can control the polarity of electricity to an attached electrical component - commonly a motor. In practice this means that a typical brushed DC motor's direction and speed can be controlled from one using two control signals. While you can make one yourself using transistors (that site also has a useful example using switches which might make the concept easier to understand too), they often come in integrated circuit (IC) form factors, such as the Texas Instruments L293D, which packs two H-bridges and comes bundled with some additional features.
Using this IO Unit, the RoboPad will send drive signals suitable for use with a H-bridge through the specified pins (PinA and PinB). It's emergency stop state is to stop all signals and power down associated pins.
- Name: The name of this HBridge motor, basically only changes the name of the motor input on the Chip Node.
- Pin A: One of the two directional signals needed by H-Bridge chips.
- Pin B: One of the two directional signals needed by H-Bridge chips, signalling the opposite direction from that signalled in Pin A.
- Enable Pin: If set to a value other than "Unset", a high signal will be transmitted whenever the H-Bridge is in use; to be connected to a H-Bridge chip's "enable" pin(s).
- Forward Scale: Scales the forward signal (over 50%) before it is transmitted to the motor signal pins - if your motor drives forward faster than backwards, then you can lower this value.
- Reverse Scale: Scales the backward signal (below 50%) before it is transmitted to the motor signal pins - if your motor drives backwards faster than forwards, then you can lower this value.
Built-in H-Bridge Motor
The "Built-in H-Bridge Motor" IO unit is a specialised version of the "H-Bridge Motor" above, specifically designed to work only with the two built-in H-Bridges on the RoboPad, allowing you to select motors to be attached to the M1 and M2 pin pairs on the board. By default, two of these are configured, one for M1 and one for M2. When in the emergency stop state, these IO Units attempt to send a stop signal to any attached motors, not powering any associated pins.
- Name: The name of this HBridge motor, basically only changes the name of the motor input on the Chip Node.
- Built-in Motor: Which of the two built-in motor pins this H-Bridge Motor IO Unit references - M1 connects to the M1 pins, M2 to the M2 pins.
- Forward Scale: Scales the forward signal (over 50%) before it is transmitted to the motor signal pins - if your motor drives forward faster than backwards, then you can lower this value.
- Backward Scale: Scales the backward signal (below 50%) before it is transmitted to the motor signal pins - if your motor drives backwards faster than forwards, then you can lower this value.
Unidirectional Brushless Motor
A brushless motor is a type of motor that uses many (usually three) electromagnetic circuits, pulsed in a specific sequence to generate a moving magnetic field - this field then "pulls" the motor's magnetised rotor with it, allowing for rotation without direct electrical contact (as is found in brushed motors, where metal brushes must transfer power directly to the rotor), resulting in motors that are less prone to wear and generally operate more smoothly and efficiently. The downside of this is that they require electronic speed controllers (ESCs) to be driven, which are circuits containing microprocessors that power the motor's coils in the correct sequential pattern. These ESCs take in a control signal, and will often require an arming sequence before they start to energise the motor's coils.
The "Unidirectional Brushless Motor" IO Unit allows the RoboPad to send drive signals (much as a traditional RC radio receiver would) suitable for reception by an ESC that can accept a PWM control signal, and will automatically send the configured arming sequence beforehand in order to initialise the ESC ready for motor control. Note that this only configures one pin as a control signal pin, and as such is designed to work with unidirectional brushless motor ESCs, i.e. ESCs that allow a single motor to be driven in a single direction at varying speeds.
- Name: The name of this brushless motor, basically only changes the name of the motor input on the Chip Node.
- Pin: Which pin will generate the ESC control signal.
- Minimum Microseconds [Advanced]: The minimum value the PWM control signal generated has (i.e. what it has when a 0/low signal is sent to the IO Unit via the nodegraph). Only change this if you know what you are doing!
- Maximum Microseconds [Advanced]: The maximum value the PWM control signal generated has (i.e. what it has when a 1/high signal is sent to the IO Unit via the nodegraph). Only change this if you know what you are doing!
- Arm Sequence: The sequence of signals that must be sent to the ESC to arm it. Refer to your ESC's manual to understand it's arming sequence and select the appropriate option here. If none match, drop us a line and tell us.