diff --git a/main.c b/main.c index 4c11f3b..a46a2a8 100644 --- a/main.c +++ b/main.c @@ -83,6 +83,16 @@ int main(void) { IntMasterEnable(); while (true) { + // handle buttons + Button button = (Button) 0; + while (fifo_get(&button)) { + switch (button) { + case S2: + drawRequested = 1; + break; + } + } + GrContextForegroundSet(&sContext, ClrBlack); GrRectFill(&sContext, &rectFullScreen); // fill screen with black