Skip to content

Commit

Permalink
Merge pull request #859 from tomlevels/patch-1
Browse files Browse the repository at this point in the history
Add Basic Support for cooling
  • Loading branch information
KartoffelToby authored Sep 20, 2023
2 parents d0cc973 + f89c0c3 commit 6c60274
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions custom_components/better_thermostat/climate.py
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ def __init__(
self._unit = unit
self._device_class = device_class
self._state_class = state_class
self._hvac_list = [HVACMode.HEAT, HVACMode.OFF]
self._hvac_list = [HVACMode.HEAT, HVACMode.COOL, HVACMode.OFF]
self.next_valve_maintenance = datetime.now() + timedelta(
hours=randint(1, 24 * 5)
)
Expand Down Expand Up @@ -702,7 +702,7 @@ async def startup(self):
self.cur_humidity = 0

self.last_window_state = self.window_open
if self.bt_hvac_mode not in (HVACMode.OFF, HVACMode.HEAT):
if self.bt_hvac_mode not in (HVACMode.OFF, HVACMode.COOL, HVACMode.HEAT):
self.bt_hvac_mode = HVACMode.HEAT

self.async_write_ha_state()
Expand Down Expand Up @@ -1077,7 +1077,7 @@ async def async_set_hvac_mode(self, hvac_mode: str) -> None:
-------
None
"""
if hvac_mode in (HVACMode.HEAT, HVACMode.OFF):
if hvac_mode in (HVACMode.HEAT, HVACMode.COOL, HVACMode.OFF):
self.bt_hvac_mode = hvac_mode
else:
_LOGGER.error(
Expand Down

0 comments on commit 6c60274

Please sign in to comment.