RoboTx.Api Namespace

The RoboTx.Api namespace contains classes for the Robo-Tx API that interacts with the Robo-Tx firmware deployed to an Arduino.

Classes

AccelValues Holds the most recent accelerometer values for the X, Y and Z axis.
Analog Configures and reports analog inputs via Arduino pins A0 to A7.
AnalogInput Represents the value of a given analog input.
ColourSensor Reports RGB and HSL values detected using TCS34725 I2C sensor. HSL values may give better results when detecting colours. For each colour to detect, obtain reference values with the sensor close to the object, and with the sensor further away. Compare readings against the range of reference values to identify the colour. This feature is only available in the Education Edition of the RoboTx API.
ConnectionState Informs the connected state of the computer with the Arduino.
ContinuousSensor Base class for any sensor that continuously reports values, after being enabled. Once the values are available, the state of the sensor is set to ready.
DHTSensor Reports temperature and relative hudity values using a DHT20 sensor. This feature is only available in the Education Edition of the RoboTx API.
Digital Configures and reports digital inputs via Arduino pins defined in the firmware profile. By default the input pins are A0 to A4, but can be overridden for a specific profile using firmware macro DIGITAL_INPUT_PINS. Digital inputs are identified by their index position. I.e. index 0 by default corresponds to A0, index 1 to A1 etc. Also reports received IR commands sent by an IR remote control.
DigitalInput Represents the value of a given digital input.
DisplayLcd Writes text to a 16x2 or 16x4 I2C LCD display.
DisplayLed Writes a string to a 4 digit 7 segment LED display. The Arduino pins assigned for the display are configured in the firmware settings.
GyroValues Holds the most recent gyrometer values for the X, Y and Z axis.
Input Input constants representing the pressing, holding and releasing of buttons, or triggering of contacts on Arduino pins defined in the firmware.
LightMeter Reports LUX values from a BH1750 sensor. This feature is only available in the Education Edition of the RoboTx API.
Motor Controls speed, acceleration, duration and direction of a motor. The Arduino pins assigned for motors are configured in the firmware settings.
MotorConfig Configuration options for DC motors.
MPUSensor Report accelerometer and gyro readings from an MPU6050 sensor. This feature is only available in the Education Edition of the RoboTx API.
PulseCounter Configures and calculates period of input pulses on configurable Arduino pin, as defined in the RoboTx firmware settings (default is A2). This feature is only available in the Education Edition of the RoboTx API.
RobotIO The main class through which input and output operations are performed with devices and components connected to the Arduino.
Servo Configures the range and the position setting of a servo motor. The Arduino pins assigned for servo motors are configured in the firmware settings.
ServoConfig Configuration options for servo motors.
ServoRange Maintains the range settings for a servo.
Sonar Uses sonar to calculate distance by sending a ping and measuring the time lapsed before receiving the echo. The maximum distance that can be measured is 165 Centimetres. Sonar works best to detect objects with hard surfaces that reflect sound well. The sonar sensor may detect a closer object off to the side instead of a farther object straight ahead. The Arduino pins assigned for the sonar module are configured in the firmware settings.
Switch Sets a digital output to on or off. The Arduino digital pin and values that represent on and off are configured in the firmware settings.
TCS34725 Symbolic labels for colour sensor configuration settings.
Trigger A digital trigger for repeating pulse cycle patterns. Use for an audio or visual alert (e.g. active beeper) using repeating cycle patterns. The Arduino digital pin and values that represent on and off are configured in the firmware settings.

Structures

HSLColour Represents colour as Hue, Saturation and Lightness values.
IrCommand Represents IR Command received by the IR remote sensor.
RGBColour Represents colour as Red, Green, Blue and Clear values.

Delegates

AnalogConverter Analog input converter
IrCommandConverter Infra red remote sensor command converter. Use for converting command codes to a string value.
MPUConverter MPU sensor converter. Use to convert raw MPU sensor readings to either calibrated values and or a different scale.