![]() |
OpenSourceSimWheelESP32
Open-source wireless steering wheel/button box for ESP32 boards
|
Button matrix hardware. More...
#include <InputHardware.hpp>
Public Member Functions | |
| ButtonMatrixInput (const ButtonMatrix &matrix, bool negativeLogic=false) | |
| Construct a new Button Matrix Input object. | |
| virtual uint64_t | read (uint64_t lastState) override |
| Read the current state of the inputs (pressed or released) | |
Public Member Functions inherited from DigitalInput | |
Additional Inherited Members | |
Public Attributes inherited from DigitalInput | |
| uint64_t | mask = ~0ULL |
| Input mask. For read-only. | |
Protected Member Functions inherited from DigitalInput | |
| void | addToMask (uint64_t bitmap) |
| Add an input bitmap to the current mask. | |
Button matrix hardware.
Definition at line 180 of file InputHardware.hpp.
| ButtonMatrixInput::ButtonMatrixInput | ( | const ButtonMatrix & | matrix, |
| bool | negativeLogic = false ) |
Construct a new Button Matrix Input object.
| matrix | Button matrix specification |
| negativeLogic | True to use negative logic |
|
overridevirtual |
Read the current state of the inputs (pressed or released)
| lastState | State of the same inputs as recorded in the previous iteration. Whether the current state is unknown, lastState must be returned (properly masked). Must be set to zero at first call. |
Implements DigitalInput.