mirror of
https://github.com/arendst/Tasmota.git
synced 2025-07-28 13:16:32 +00:00
Allow deepsleep to wait for second TELEPERIOD intervall
Compatible with old values teleperiod10 or 300 to start deepsleep immediately asap. All Other values (at least >15, because this is often min runtime) for teleperiod causes the device to wait for another teleperiod eventually fix for #7295
This commit is contained in:
parent
7695a2c5bf
commit
3fee364fd7
@ -192,7 +192,7 @@ bool Xdrv29(uint8_t function)
|
|||||||
DeepSleepEverySecond();
|
DeepSleepEverySecond();
|
||||||
break;
|
break;
|
||||||
case FUNC_AFTER_TELEPERIOD:
|
case FUNC_AFTER_TELEPERIOD:
|
||||||
if (DeepSleepEnabled() && !deepsleep_flag) {
|
if (DeepSleepEnabled() && !deepsleep_flag && (Settings.tele_period == 10 || Settings.tele_period == 300 || UpTime() > Settings.tele_period)) {
|
||||||
deepsleep_flag = DEEPSLEEP_START_COUNTDOWN; // Start deepsleep in 4 seconds
|
deepsleep_flag = DEEPSLEEP_START_COUNTDOWN; // Start deepsleep in 4 seconds
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user