void handleReportingState()
void handleSleepingState()
SLEEPING_STATE: deep sleep between reporting intervals.
void handleOccupancyMode()
Handle sensor events in OCCUPANCY mode.
void updateOccupancyState()
Update occupancy state based on debounce timeout.
void handleConnectingState()
CONNECTING_STATE: establish cloud connection using a phased, non-blocking state machine.
void handleFirmwareUpdateState()
void handleCountingMode()
Handle sensor events in COUNTING mode.