Module ext_adi

Module ext_adi 

Source
Expand description

Contains prototypes for interfacing with the 3-Wire Expander.

Functions§

ext_adi_analog_calibrate
Calibrates the analog sensor on the specified port and returns the new calibration value.
ext_adi_analog_read
Gets the 12-bit value of the specified port.
ext_adi_analog_read_calibrated
Gets the 12 bit calibrated value of an analog input port.
ext_adi_analog_read_calibrated_HR
Gets the 16 bit calibrated value of an analog input port.
ext_adi_digital_get_new_press
Gets a rising-edge case for a digital button press.
ext_adi_digital_read
Gets the digital value (1 or 0) of a port configured as a digital input.
ext_adi_digital_write
Sets the digital value (1 or 0) of a port configured as a digital output.
ext_adi_encoder_get
Gets the number of ticks recorded by the encoder.
ext_adi_encoder_init
Creates an encoder object and configures the specified ports accordingly.
ext_adi_encoder_reset
Sets the encoder value to zero.
ext_adi_encoder_shutdown
Disables the encoder and voids the configuration on its ports.
ext_adi_gyro_get
Gets the current gyro angle in tenths of a degree. Unless a multiplier is applied to the gyro, the return value will be a whole number representing the number of degrees of rotation times 10.
ext_adi_gyro_init
Initializes a gyroscope on the given port. If the given port has not previously been configured as a gyro, then this function starts a 1300 ms calibration period.
ext_adi_gyro_reset
Resets the gyroscope value to zero.
ext_adi_gyro_shutdown
Disables the gyro and voids the configuration on its port.
ext_adi_led_clear_all
@brief Clear the entire led strip of color
ext_adi_led_clear_pixel
@brief Clear one pixel on the led strip
ext_adi_led_init
Initializes a led on the given port.
ext_adi_led_set
@brief Set the entire led strip using the colors contained in the buffer
ext_adi_led_set_all
@brief Set the entire led strip to one color
ext_adi_led_set_pixel
@brief Set one pixel on the led strip
ext_adi_motor_get
Gets the last set speed of the motor on the given port.
ext_adi_motor_set
Sets the speed of the motor on the given port.
ext_adi_motor_stop
Stops the motor on the given port.
ext_adi_pin_mode
Configures the port as an input or output with a variety of settings.
ext_adi_port_get_config
Gets the configuration for the given ADI port.
ext_adi_port_get_value
Gets the value for the given ADI port.
ext_adi_port_set_config
Configures an ADI port to act as a given sensor type.
ext_adi_port_set_value
Sets the value for the given ADI port.
ext_adi_potentiometer_get_angle
Gets the current potentiometer angle in tenths of a degree.
ext_adi_potentiometer_init
Initializes a potentiometer on the given port.
ext_adi_ultrasonic_get
Gets the current ultrasonic sensor value in centimeters.
ext_adi_ultrasonic_init
Creates an ultrasonic object and configures the specified ports accordingly.
ext_adi_ultrasonic_shutdown
Disables the ultrasonic sensor and voids the configuration on its ports.

Type Aliases§

ext_adi_encoder_t
Reference type for an initialized encoder.
ext_adi_gyro_t
Reference type for an initialized gyroscope.
ext_adi_led_t
Reference type for an initialized addressable led, which stores its smart and adi port.
ext_adi_potentiometer_t
Reference type for an initialized potentiometer.
ext_adi_ultrasonic_t
Reference type for an initialized ultrasonic.