|
@ -86,6 +86,12 @@ void _systemSetupHeartbeat() { |
|
|
_heartbeat_interval = getSetting("hbInterval", HEARTBEAT_INTERVAL).toInt(); |
|
|
_heartbeat_interval = getSetting("hbInterval", HEARTBEAT_INTERVAL).toInt(); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
#if WEB_SUPPORT
|
|
|
|
|
|
bool _systemWebSocketOnReceive(const char * key, JsonVariant& value) { |
|
|
|
|
|
return (strncmp(key, "hb", 2) == 0); |
|
|
|
|
|
} |
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
void systemLoop() { |
|
|
void systemLoop() { |
|
|
|
|
|
|
|
|
// -------------------------------------------------------------------------
|
|
|
// -------------------------------------------------------------------------
|
|
@ -182,6 +188,10 @@ void systemSetup() { |
|
|
systemCheck(false); |
|
|
systemCheck(false); |
|
|
#endif
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
#if WEB_SUPPORT
|
|
|
|
|
|
wsOnReceiveRegister(_systemWebSocketOnReceive); |
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
// Init device-specific hardware
|
|
|
// Init device-specific hardware
|
|
|
_systemSetupSpecificHardware(); |
|
|
_systemSetupSpecificHardware(); |
|
|
|
|
|
|
|
|