diff options
Diffstat (limited to 'firmware/include/inputs')
| -rw-r--r-- | firmware/include/inputs/button.h | 16 | ||||
| -rw-r--r-- | firmware/include/inputs/input.h | 23 |
2 files changed, 39 insertions, 0 deletions
diff --git a/firmware/include/inputs/button.h b/firmware/include/inputs/button.h new file mode 100644 index 0000000..c3530ae --- /dev/null +++ b/firmware/include/inputs/button.h @@ -0,0 +1,16 @@ +#pragma once + +#include <cstdint> + +namespace inputs { + +class Button { +public: + Button(uint8_t pin); + + bool is_pressed(); + +private: +}; + +} diff --git a/firmware/include/inputs/input.h b/firmware/include/inputs/input.h new file mode 100644 index 0000000..7899ce7 --- /dev/null +++ b/firmware/include/inputs/input.h @@ -0,0 +1,23 @@ +#pragma once + +#include "inputs/button.h" + +namespace inputs { + +class Input { +public: + Input(/* pins */); + + void init(); + + bool down_pressed(); + bool up_pressed(); + bool right_pressed(); + bool left_pressed(); + bool a_pressed(); + bool b_pressed(); + +private: +}; + +} |