diff --git a/.vscode/settings.json b/.vscode/settings.json index cfeb942..cfb9892 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -72,4 +72,4 @@ "utility": "cpp", "cinttypes": "cpp" } -} \ No newline at end of file +} diff --git a/components/ratgdo/ratgdo.cpp b/components/ratgdo/ratgdo.cpp index 9983dbf..73c3553 100644 --- a/components/ratgdo/ratgdo.cpp +++ b/components/ratgdo/ratgdo.cpp @@ -194,34 +194,34 @@ namespace ratgdo { void RATGDOComponent::received(const LightState light_state) { - // auto last_state = this->light_state; - // if(last_state == light_state){ - // return; - // } + // auto last_state = this->light_state; + // if(last_state == light_state){ + // return; + // } - ESP_LOGD(TAG, "Light state=%s", LightState_to_string(light_state)); + ESP_LOGD(TAG, "Light state=%s", LightState_to_string(light_state)); this->light_state = light_state; } void RATGDOComponent::received(const LockState lock_state) { - // static LockState last_state = LockState::UNKNOWN; - // if(light_state != last_state){ - ESP_LOGD(TAG, "Lock state=%s", LockState_to_string(lock_state)); - // } + // static LockState last_state = LockState::UNKNOWN; + // if(light_state != last_state){ + ESP_LOGD(TAG, "Lock state=%s", LockState_to_string(lock_state)); + // } this->lock_state = lock_state; } void RATGDOComponent::received(const ObstructionState obstruction_state) { - // static ObstructionState last_state = ObstructionState::UNKNOWN; + // static ObstructionState last_state = ObstructionState::UNKNOWN; if (!this->obstruction_sensor_detected_) { - // if(obstruction_state != last_state){ - // ESP_LOGD(TAG, "Obstruction: state=%s", ObstructionState_to_string(*this->obstruction_state)); - // } + // if(obstruction_state != last_state){ + // ESP_LOGD(TAG, "Obstruction: state=%s", ObstructionState_to_string(*this->obstruction_state)); + // } this->obstruction_state = obstruction_state; // This isn't very fast to update, but its still better diff --git a/components/ratgdo/secplus1.cpp b/components/ratgdo/secplus1.cpp index f01b37e..b50293a 100644 --- a/components/ratgdo/secplus1.cpp +++ b/components/ratgdo/secplus1.cpp @@ -69,9 +69,9 @@ namespace ratgdo { void Secplus1::wall_panel_emulation(size_t index) { - if (this->wall_panel_emulation_state_ == WallPanelEmulationState::DISABLED){ + if (this->wall_panel_emulation_state_ == WallPanelEmulationState::DISABLED) { ESP_LOGD(TAG, "Emulation mode is disabled"); - } else if (this->wall_panel_emulation_state_ == WallPanelEmulationState::ENABLED) { + } else if (this->wall_panel_emulation_state_ == WallPanelEmulationState::ENABLED) { // ESP_LOG2(TAG, "[Wall panel emulation] Sending byte: [%02X]", secplus1_states[index]); if (index < 15 || !this->do_transmit_if_pending()) {