Skip to content

Commit

Permalink
Fix on / off pilote v2
Browse files Browse the repository at this point in the history
  • Loading branch information
cyr-ius committed Dec 7, 2024
1 parent 1ef2859 commit 7329cdd
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions custom_components/heatzy/climate.py
Original file line number Diff line number Diff line change
Expand Up @@ -494,12 +494,14 @@ class HeatzyPiloteV2Thermostat(HeatzyThermostat):
async def async_turn_on(self) -> None:
"""Turn device on."""
await self._derog_mode_off()
await self.async_set_preset_mode(PRESET_COMFORT)
config = {CONF_ATTRS: {CONF_MODE: PRESET_COMFORT}}
await self._handle_action(config, "Error while turn off")

async def async_turn_off(self) -> None:
"""Turn device on."""
await self._derog_mode_off()
await self.async_set_preset_mode(self.entity_description.stop)
config = {CONF_ATTRS: {CONF_MODE: self.entity_description.stop}}
await self._handle_action(config, "Error while turn off")

async def async_turn_auto(self) -> None:
"""Turn device to Program mode."""
Expand Down

0 comments on commit 7329cdd

Please sign in to comment.