mirror of https://github.com/arendst/Tasmota.git
Fix reset to defaults after 6 hours of DeepSleep
Fix reset to defaults after 6 hours of DeepSleep (#9993)
This commit is contained in:
parent
ff8b2efd5e
commit
4b5dbe7a86
|
@ -23,6 +23,7 @@ All notable changes to this project will be documented in this file.
|
|||
- KNX ESP32 UDP mulicastpackage (#9811)
|
||||
- Command ``gpio`` using non-indexed functions regression from v9.1.0 (#9962)
|
||||
- ESP32 TasmotaClient firmware upgrade (#9218)
|
||||
- Reset to defaults after 6 hours of DeepSleep (#9993)
|
||||
|
||||
### Removed
|
||||
|
||||
|
|
|
@ -90,6 +90,7 @@ The attached binaries can also be downloaded from http://ota.tasmota.com/tasmota
|
|||
- KNX ESP32 UDP mulicastpackage (#9811)
|
||||
- GUI MqttUser and MqttPassword updates when TLS is compiled in (#9825)
|
||||
- ESP32 TasmotaClient firmware upgrade (#9218)
|
||||
- Reset to defaults after 6 hours of DeepSleep (#9993)
|
||||
|
||||
### Removed
|
||||
- Version compatibility check
|
||||
|
|
|
@ -287,6 +287,8 @@ void UpdateQuickPowerCycle(bool update) {
|
|||
#ifndef FIRMWARE_MINIMAL
|
||||
if (Settings.flag3.fast_power_cycle_disable) { return; } // SetOption65 - Disable fast power cycle detection for device reset
|
||||
|
||||
|
||||
|
||||
const uint32_t QPC_COUNT = 7; // Number of Power Cycles before Settings erase
|
||||
const uint32_t QPC_SIGNATURE = 0xFFA55AFF;
|
||||
|
||||
|
|
|
@ -205,9 +205,13 @@ void setup(void) {
|
|||
RtcReboot.fast_reboot_count = 0;
|
||||
}
|
||||
#ifdef FIRMWARE_MINIMAL
|
||||
RtcReboot.fast_reboot_count = 0; // Disable fast reboot and quick power cycle detection
|
||||
RtcReboot.fast_reboot_count = 0; // Disable fast reboot and quick power cycle detection
|
||||
#else
|
||||
RtcReboot.fast_reboot_count++;
|
||||
if (ResetReason() == REASON_DEEP_SLEEP_AWAKE) {
|
||||
RtcReboot.fast_reboot_count = 0; // Disable fast reboot and quick power cycle detection
|
||||
} else {
|
||||
RtcReboot.fast_reboot_count++;
|
||||
}
|
||||
#endif
|
||||
RtcRebootSave();
|
||||
|
||||
|
@ -229,7 +233,6 @@ void setup(void) {
|
|||
|
||||
if (1 == RtcReboot.fast_reboot_count) { // Allow setting override only when all is well
|
||||
UpdateQuickPowerCycle(true);
|
||||
XdrvCall(FUNC_SETTINGS_OVERRIDE);
|
||||
}
|
||||
|
||||
TasmotaGlobal.seriallog_level = Settings.seriallog_level;
|
||||
|
|
Loading…
Reference in New Issue