File tree Expand file tree Collapse file tree 1 file changed +9
-4
lines changed
Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -593,9 +593,16 @@ namespace ratgdo {
593593 this ->door_action_delayed = DoorActionDelayed::NO;
594594 this ->protocol_ ->door_action (DoorAction::CLOSE);
595595 });
596- } else {
597- this ->protocol_ ->door_action (action);
596+ return ;
597+ }
598+
599+ if (action == DoorAction::STOP || action == DoorAction::TOGGLE) {
600+ // Door will likely be open partially unless closed
601+ if (*this ->door_state == DoorState::OPENING || *this ->door_state == DoorState::CLOSING) {
602+ this ->received (DoorState::OPEN);
603+ }
598604 }
605+ this ->protocol_ ->door_action (action);
599606 }
600607
601608 void RATGDOComponent::door_move_to_position (float position)
@@ -629,8 +636,6 @@ namespace ratgdo {
629636 this ->door_action (delta > 0 ? DoorAction::OPEN : DoorAction::CLOSE);
630637 set_timeout (" move_to_position" , operation_time, [this ] {
631638 this ->door_action (DoorAction::STOP);
632- this ->received (DoorState::OPEN);
633- this ->cancel_position_sync_callbacks ();
634639 });
635640 }
636641
You can’t perform that action at this time.
0 commit comments