From 4ff85b92711ff1761ef54b0fccb6c4d238eca318 Mon Sep 17 00:00:00 2001 From: I-am-nightingale Date: Thu, 11 Apr 2024 21:54:51 +0300 Subject: [PATCH] =?UTF-8?q?=D0=98=20=D0=BF=D0=BE=D1=81=D1=82=D0=BE=D1=8F?= =?UTF-8?q?=D0=BD=D0=BD=D0=BE=20=D0=B2=D1=8B=D0=BB=D0=B5=D0=B7=D0=B0=D1=8E?= =?UTF-8?q?=D1=82=20=D0=BA=D0=B0=D0=BA=D0=B8=D0=B5-=D1=82=D0=BE=20=D0=BD?= =?UTF-8?q?=D0=BE=D0=B2=D1=8B=D0=B5=20=D0=B8=20=D0=BD=D0=BE=D0=B2=D1=8B?= =?UTF-8?q?=D0=B5=20=D0=BA=D0=BE=D1=81=D1=8F=D0=BA=D0=B8.=20=D0=92=D0=BE?= =?UTF-8?q?=D0=BE=D0=B1=D1=89=D0=B5=20=D0=BD=D0=B5=20=D0=BF=D0=BE=D0=BD?= =?UTF-8?q?=D0=B8=D0=BC=D0=B0=D1=8E,=20=D0=BA=D0=B0=D0=BA=20=D1=81=20?= =?UTF-8?q?=D0=BD=D0=B8=D0=BC=D0=B8=20=D1=81=D0=BE=20=D0=B2=D1=81=D0=B5?= =?UTF-8?q?=D0=BC=D0=B8=20=D0=B1=D0=BE=D1=80=D0=BE=D1=82=D1=8C=D1=81=D1=8F?= =?UTF-8?q?...?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/tclac/tclac.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/components/tclac/tclac.cpp b/components/tclac/tclac.cpp index dc6a1f5..fd5d529 100644 --- a/components/tclac/tclac.cpp +++ b/components/tclac/tclac.cpp @@ -181,7 +181,7 @@ void tclacClimate::readData() { // Публикуем данные this->publish_state(); allow_take_control = true; - } + } // Climate control void tclacClimate::control(const ClimateCall &call) { @@ -213,7 +213,6 @@ void tclacClimate::control(const ClimateCall &call) { target_temperature_set = 31-(int)target_temperature; } - takeControl(); allow_take_control = true; } @@ -406,7 +405,7 @@ void tclacClimate::takeControl() { break; } // Устанавливаем положение фиксации вертикальной заслонки - switch(this->vertical_direction_) { + switch(vertical_direction_) { case AirflowVerticalDirection::LAST: dataTX[32] += 0b00000000; ESP_LOGD("TCL", "Vertical fix: last position"); @@ -433,7 +432,7 @@ void tclacClimate::takeControl() { break; } // Устанавливаем положение фиксации горизонтальных заслонок - switch(this->horizontal_direction_) { + switch(horizontal_direction_) { case AirflowHorizontalDirection::LAST: dataTX[33] += 0b00000000; ESP_LOGD("TCL", "Horizontal fix: last position"); @@ -643,7 +642,7 @@ void tclacClimate::set_supported_modes(const std::set &mod } // Получение режима качания горизонтальных заслонок void tclacClimate::set_horizontal_swing_direction(HorizontalSwingDirection direction) { - this->horizontal_swing_direction_ = direction; + horizontal_swing_direction_ = direction; if (force_mode_status_){ if (allow_take_control){ tclacClimate::takeControl();