diff options
| author | Christian Krinitsin <mail@krinitsin.com> | 2025-03-26 20:47:12 +0100 |
|---|---|---|
| committer | Christian Krinitsin <mail@krinitsin.com> | 2025-03-26 20:47:12 +0100 |
| commit | 32a24182ad8cd2fc3a9125cb8f70de3b9c22f9a4 (patch) | |
| tree | f2d3a9a1696d50ae28e88e9ba94684bf5ffee5d3 /firmware/src/ui/ui.cpp | |
| parent | 6b3fb653f8b342d8ecfc093a000e9f6fa479c644 (diff) | |
| download | tetris-console-32a24182ad8cd2fc3a9125cb8f70de3b9c22f9a4.tar.gz tetris-console-32a24182ad8cd2fc3a9125cb8f70de3b9c22f9a4.zip | |
add preliminary public apis
Diffstat (limited to '')
| -rw-r--r-- | firmware/src/ui/ui.cpp | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/firmware/src/ui/ui.cpp b/firmware/src/ui/ui.cpp new file mode 100644 index 0000000..af27b37 --- /dev/null +++ b/firmware/src/ui/ui.cpp @@ -0,0 +1,21 @@ +#include "ui/ui.h" +#include "game/game_state.h" + +namespace ui { + +UI::UI(int8_t tft_cs, int8_t tft_rst, int8_t tft_dc) + : tft { tft_cs, tft_rst, tft_dc } +{ +} + +void UI::init() +{ + tft.initR(INITR_BLACKTAB); +} + +void UI::render_screen(const game::GameState& state) +{ + // TODO +} + +} |