1234567891011121314151617181920212223 |
- #ifndef ROW_H
- #define ROW_H
-
- #include <Arduino.h>
- #include <inttypes.h>
- #include <config_keybrd.h>
- #include <Key.h>
-
- /* Row is an abstract base class.
- */
- class Row
- {
- private:
- Key *const *const ptrsKeys; //array of Key pointers
- virtual void keyWasPressed();
- protected:
- read_pins_t debounced; //bitwise state of keys after debouncing, 1=pressed, 0=released
- void send(const uint8_t readPinCount, const read_pins_t debouncedChanged);
- public:
- Row(Key* const ptrsKeys[]) : ptrsKeys(ptrsKeys), debounced(0) { }
- virtual void process()=0;
- };
- #endif
|