InputEvents v1.4.0
An easy to use but comprehensive Event Library for Buttons, Encoders, Encoder Buttons, Analog Inputs, Joysticks and Switches.
PinAdapter.h
1#ifndef PinAdapter_h
2#define PinAdapter_h
3
8class PinAdapter {
9 public:
14 virtual void begin() = 0;
21 virtual bool read() = 0;
22
23 virtual ~PinAdapter() = default;
24};
25
26#endif
The interface specification for button, encoder button and switch pins.
Definition: PinAdapter.h:8
virtual bool read()=0
Read the current state of the pin.
virtual void begin()=0
Initialise the pin adapter. Must be safe for repeated calls (Idempotent)