Button¶
EV3 Buttons
Event handlers
These will be called when state of the corresponding button is changed:
Member functions and properties
Returns list of names of pressed buttons.
Checks if any button is pressed.
Check if
backspace
button is pressed.
Check if currently pressed buttons exactly match the given list
buttons
.
Check if
down
button is pressed.
Check if
enter
button is pressed.
Return our corresponding evdev device object
Check if
left
button is pressed.
This handler is called by
process()
whenever state of any button has changed since lastprocess()
call.changed_buttons
is a list of tuples of changed button names and their states.
Check for currenly pressed buttons. If the
new_state
differs from the old state, call the appropriate button event handlers (on_up, on_down, etc).
Check if
right
button is pressed.
Check if
up
button is pressed.
Wait for
buttons
to be pressed down and then released. Both actions must happen withintimeout_ms
.
Wait for
buttons
to be pressed down.
Wait for
buttons
to be released.