disable all automatic restarts when OTA has started

This commit is contained in:
technyon
2022-07-21 18:31:46 +02:00
parent 2ade696e8b
commit a24bb4b0c2
9 changed files with 35 additions and 7 deletions

View File

@@ -9,7 +9,6 @@ W5500Device::W5500Device(const String &hostname, Preferences* preferences)
_preferences(preferences)
{
initializeMacAddress(_mac);
_restartOnDisconnect = _preferences->getBool(preference_restart_on_disconnect);
Serial.print("MAC Adress: ");
for(int i=0; i < 6; i++)
@@ -47,10 +46,7 @@ void W5500Device::initialize()
bool W5500Device::reconnect()
{
if(_restartOnDisconnect && millis() > 60000)
{
ESP.restart();
}
_hasDHCPAddress = false;