clean up and add ifdef's for event loop stuff

This commit is contained in:
Brett Christensen 2024-02-09 15:17:08 +11:00
parent 8e38e8562f
commit 9b47043aba
4 changed files with 21 additions and 13 deletions

View file

@ -30,6 +30,7 @@ void init_events(void) {
}
void set_event(EVENTS_ENUM_TYPE event, uint8_t data) {
#ifdef EVENTLOGGING
if (event >= EVENT_NOF_EVENTS) {
event = EVENT_UNKNOWN_EVENT_SET;
}
@ -40,6 +41,7 @@ void set_event(EVENTS_ENUM_TYPE event, uint8_t data) {
#ifdef DEBUG_VIA_USB
Serial.println("Set event: " + String(get_event_enum_string(event)) + ". Has occured " + String(entries[event].occurences) + " times");
#endif
#endif
}
void update_event_timestamps(void) {