add restart reason to sysinfo page

This commit is contained in:
technyon
2023-02-05 15:03:09 +01:00
parent d72970e46b
commit b3c5a93666
9 changed files with 104 additions and 17 deletions

View File

@@ -5,6 +5,7 @@
#include "PreferencesKeys.h"
#include "Pins.h"
#include "Logger.h"
#include "RestartReason.h"
NetworkLock::NetworkLock(Network* network, Preferences* preferences)
: _network(network),
@@ -81,7 +82,7 @@ void NetworkLock::onMqttDataReceived(const char* topic, byte* payload, const uns
{
Log->println(F("Restart requested via MQTT."));
delay(200);
ESP.restart();
restartEsp(RestartReason::RequestedViaMqtt);
}
if(processActions && comparePrefixedPath(topic, mqtt_topic_lock_action))