#pragma once #include enum class DeviceState : uint8_t { SILENT, ALERTING, WAKE }; enum class ScreenID : uint8_t { BOOT_SPLASH, WIFI_CONNECTING, WIFI_CONNECTED, WIFI_FAILED, ALERT, STATUS, DASHBOARD, OFF }; #define ALERT_HISTORY_SIZE 3 struct AlertRecord { char message[64] = ""; char timestamp[12] = ""; }; struct ScreenState { ScreenID screen = ScreenID::BOOT_SPLASH; DeviceState deviceState = DeviceState::SILENT; bool blinkPhase = false; char alertMessage[64] = ""; bool wifiConnected = false; char wifiSSID[33] = ""; int wifiRSSI = 0; char wifiIP[16] = ""; bool ntpSynced = false; char timeString[12] = ""; uint32_t uptimeMinutes = 0; uint32_t freeHeapKB = 0; bool networkOK = false; bool debugMode = false; AlertRecord alertHistory[ALERT_HISTORY_SIZE] = {}; int alertHistoryCount = 0; }; struct TouchEvent { bool pressed = false; uint16_t x = 0; uint16_t y = 0; };