diff options
author | sanine <sanine.not@pm.me> | 2023-10-19 20:12:24 -0500 |
---|---|---|
committer | sanine <sanine.not@pm.me> | 2023-10-19 20:12:24 -0500 |
commit | a91ba5a9d7ced85277ad60f1dbf381192f5c5ed8 (patch) | |
tree | 7223cb8bf4440edf84a2c6e54e7f480dcb1be52e /12key-arduino/ModeMenu.h | |
parent | e55263a0a250dea2bf567df8dcbad8ca3580b10c (diff) |
updatemain
Diffstat (limited to '12key-arduino/ModeMenu.h')
-rw-r--r-- | 12key-arduino/ModeMenu.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/12key-arduino/ModeMenu.h b/12key-arduino/ModeMenu.h new file mode 100644 index 0000000..7203b30 --- /dev/null +++ b/12key-arduino/ModeMenu.h @@ -0,0 +1,13 @@ +#include <Arduino.h> +#include "Mode.h" + + +class ModeMenu : public Mode { + void reset() {} + Mode * update(unsigned int keys) { + if (keys & KEY_1) return Mode::modes[1]; + if (keys & KEY_2) return Mode::modes[2]; + if (keys & KEY_3) return Mode::modes[3]; + return NULL; + } +}; |