![]() |
OpenSourceSimWheelESP32
Open-source wireless steering wheel/button box for ESP32 boards
|
Single button. More...
#include <InputHardware.hpp>
Public Member Functions | |
| DigitalButton (InputGPIO pinNumber, InputNumber buttonNumber) | |
| Construct a new Digital Button 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 | |
Protected Attributes | |
| InputGPIO | pinNumber |
| Configured input pin. | |
| uint64_t | bitmap |
| Input bitmap. | |
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. | |
Single button.
Definition at line 75 of file InputHardware.hpp.
| DigitalButton::DigitalButton | ( | InputGPIO | pinNumber, |
| InputNumber | buttonNumber ) |
Construct a new Digital Button object.
| [in] | pinNumber | GPIO pin where the button is attached to |
| [in] | buttonNumber | Assigned number for this button |
|
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.
|
protected |
Input bitmap.
Definition at line 81 of file InputHardware.hpp.
|
protected |
Configured input pin.
Definition at line 79 of file InputHardware.hpp.