Reboot Mode Added

This commit is contained in:
richonguzman 2024-05-22 19:19:25 -04:00
parent 960df01d61
commit 51f9e0f0cc
9 changed files with 160 additions and 58 deletions

View file

@ -262,4 +262,19 @@ namespace Utils {
}
}
void checkRebootMode() {
if (Config.rebootMode && Config.rebootModeTime > 0) {
Serial.println("(Reboot Time Set to " + String(Config.rebootModeTime) + " hours)");
}
}
void checkRebootTime() {
if (Config.rebootMode && Config.rebootModeTime > 0) {
if (millis() > Config.rebootModeTime * 60 * 60 * 1000) {
Serial.println("\n*** Automatic Reboot Time Restart! ****\n");
ESP.restart();
}
}
}
}