mirror of
https://github.com/esphome/esphome.git
synced 2024-12-22 13:34:54 +01:00
Climate IR LG -keep previous temp and fan if swing (#1556)
Swing IR command does not carry CLIMATE_FAN or TEMP within itself, so previous states sould be kept. Tested with actual LG IR remote controller.
This commit is contained in:
parent
3d0310d0e0
commit
92b36720b6
1 changed files with 15 additions and 15 deletions
|
@ -139,7 +139,6 @@ bool LgIrClimate::on_receive(remote_base::RemoteReceiveData data) {
|
||||||
} else {
|
} else {
|
||||||
this->mode = climate::CLIMATE_MODE_COOL;
|
this->mode = climate::CLIMATE_MODE_COOL;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
// Temperature
|
// Temperature
|
||||||
if (this->mode == climate::CLIMATE_MODE_COOL)
|
if (this->mode == climate::CLIMATE_MODE_COOL)
|
||||||
|
@ -158,6 +157,7 @@ bool LgIrClimate::on_receive(remote_base::RemoteReceiveData data) {
|
||||||
else if ((remote_state & FAN_MASK) == FAN_MAX)
|
else if ((remote_state & FAN_MASK) == FAN_MAX)
|
||||||
this->fan_mode = climate::CLIMATE_FAN_HIGH;
|
this->fan_mode = climate::CLIMATE_FAN_HIGH;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
this->publish_state();
|
this->publish_state();
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|
Loading…
Reference in a new issue