trikRuntime
|
Implementation of handler for keys on a brick for a real robot. More...
#include <keys.h>
Public Slots | |
void | reset () override |
bool | wasPressed (int code) override |
bool | isPressed (int code) override |
int | buttonCode (bool wait=true) override |
Public Slots inherited from trikControl::KeysInterface | |
virtual void | reset ()=0 |
Clear data about previous key pressures. More... | |
virtual bool | wasPressed (int code)=0 |
Returns true if button with given code was pressed, and clears "pressed" state for that button. More... | |
virtual bool | isPressed (int code)=0 |
Returns true if button with given code is pressed at the moment. More... | |
virtual int | buttonCode (bool wait=true)=0 |
Returns a code of a pressed button. More... | |
Public Member Functions | |
Keys (const trikKernel::Configurer &configurer, const trikHal::HardwareAbstractionInterface &hardwareAbstraction) | |
Constructor. More... | |
~Keys () override | |
Status | status () const override |
Returns current status of the device. More... | |
Public Member Functions inherited from trikControl::DeviceInterface | |
DeviceInterface ()=default | |
virtual | ~DeviceInterface ()=default |
Additional Inherited Members | |
Public Types inherited from trikControl::DeviceInterface | |
enum | Status { Status::permanentFailure, Status::temporaryFailure, Status::off, Status::starting, Status::ready, Status::stopping } |
Device status. More... | |
Signals inherited from trikControl::KeysInterface | |
void | buttonPressed (int code, int value) |
Triggered when button state changed (pressed or released). More... | |
Static Public Member Functions inherited from trikControl::DeviceInterface | |
static Status | combine (const DeviceInterface &underlying, const DeviceInterface::Status &dependent) |
Helper method to return status of a device relying on other device to work. More... | |
Implementation of handler for keys on a brick for a real robot.
Keys::Keys | ( | const trikKernel::Configurer & | configurer, |
const trikHal::HardwareAbstractionInterface & | hardwareAbstraction | ||
) |
Constructor.
configurer | - configurer object containing preparsed XML files with sensor parameters. |
|
override |
|
overrideslot |
|
overrideslot |
|
overrideslot |
|
overridevirtual |
Returns current status of the device.
Implements trikControl::DeviceInterface.
|
overrideslot |