mirror of
https://github.com/arendst/Tasmota.git
synced 2026-07-28 04:15:53 +00:00
Fix shutter restart (#23939)
This commit is contained in:
@@ -1383,8 +1383,7 @@ void ShutterUpdateVelocity(uint8_t i)
|
||||
|
||||
void ShutterWaitForMotorStart(uint8_t i)
|
||||
{
|
||||
uint32_t end_time = Shutter[i].last_stop_time + ShutterSettings.shutter_motorstop;
|
||||
while (!TimeReached(end_time)) {
|
||||
while (millis() - Shutter[i].last_stop_time < ShutterSettings.shutter_motorstop) { // statement is overflow proof
|
||||
loop();
|
||||
}
|
||||
//AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("SHT: Stoptime done"));
|
||||
|
||||
@@ -656,8 +656,7 @@ void ShutterWaitForMotorStop(uint8_t i)
|
||||
|
||||
void ShutterWaitForMotorStart(uint8_t i)
|
||||
{
|
||||
uint32_t end_time = Shutter[i].last_stop_time + Settings->shutter_motorstop;
|
||||
while (!TimeReached(end_time)) {
|
||||
while (millis() - Shutter[i].last_stop_time < Settings->shutter_motorstop) { // statement is overflow proof
|
||||
loop();
|
||||
}
|
||||
//AddLog(LOG_LEVEL_DEBUG_MORE, PSTR("SHT: Stoptime done"));
|
||||
|
||||
Reference in New Issue
Block a user