Skip to content

Commit 95eabcb

Browse files
authored
Wall panel detection (#306)
* Fix wall panel detection
1 parent 348e440 commit 95eabcb

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

components/ratgdo/secplus1.cpp

+3-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,9 @@ namespace ratgdo {
6464

6565
void Secplus1::wall_panel_emulation(size_t index)
6666
{
67-
if (this->wall_panel_emulation_state_ == WallPanelEmulationState::WAITING) {
67+
if (this->wall_panel_starting_) {
68+
this->wall_panel_emulation_state_ = WallPanelEmulationState::WAITING;
69+
} else if (this->wall_panel_emulation_state_ == WallPanelEmulationState::WAITING) {
6870
ESP_LOGD(TAG, "Looking for security+ 1.0 wall panel...");
6971

7072
if (this->door_state != DoorState::UNKNOWN || this->light_state != LightState::UNKNOWN) {

0 commit comments

Comments
 (0)