OnBoardIO

class romi.OnBoardIO(dio1: romi._romi.OnBoardIO.ChannelMode, dio2: romi._romi.OnBoardIO.ChannelMode)

Bases: pybind11_object

This class represents the onboard IO of the Romi reference robot. This includes the pushbuttons and LEDs.

DIO 0 - Button A (input only) DIO 1 - Button B (input) or Green LED (output) DIO 2 - Button C (input) or Red LED (output) DIO 3 - Yellow LED (output only)

class ChannelMode(value: SupportsInt | SupportsIndex)

Bases: pybind11_object

Mode for Romi onboard IO

Members:

INPUT : Input

OUTPUT : Output

INPUT = <ChannelMode.INPUT: 0>
OUTPUT = <ChannelMode.OUTPUT: 1>
OnBoardIO.ChannelMode.name -> str
property value
getButtonAPressed() bool

Gets if the A button is pressed.

getButtonBPressed() bool

Gets if the B button is pressed.

getButtonCPressed() bool

Gets if the C button is pressed.

kMessageInterval = 1.0
setGreenLed(value: bool) None

Sets the green LED.

setRedLed(value: bool) None

Sets the red LED.

setYellowLed(value: bool) None

Sets the yellow LED.