From 0499082b50b00d942e00d2d272a0c74b4c5ca1cd Mon Sep 17 00:00:00 2001 From: Selene ToyKeeper Date: Wed, 22 Aug 2018 23:28:35 -0600 Subject: Reduced ROM size by making successive nice_delay_ms calls collapse any time the user completes an input sequence. All nice delays then get aborted until the next trip through the main() loop. Eliminates the need to wrap nice_delay_ms() calls and handle the exit condition. Also eliminates the risk of getting the UI out of sync with button events. --- spaghetti-monster/fsm-events.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'spaghetti-monster/fsm-events.c') diff --git a/spaghetti-monster/fsm-events.c b/spaghetti-monster/fsm-events.c index b8e9018..aa5c3d6 100644 --- a/spaghetti-monster/fsm-events.c +++ b/spaghetti-monster/fsm-events.c @@ -39,6 +39,12 @@ uint8_t compare_event_sequences(uint8_t *a, const uint8_t *b) { void empty_event_sequence() { for(uint8_t i=0; i