diff --git a/CHANGELOG.md b/CHANGELOG.md index 473a4c35a..df518d7bf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## Ongoing + +- Revert removal of set_temperature_offset() function. + ## v0.37.5 - Add setting the thermostat temperature_offset to the set_number() function. diff --git a/plugwise/__init__.py b/plugwise/__init__.py index d9e575cc8..9ccbf8335 100644 --- a/plugwise/__init__.py +++ b/plugwise/__init__.py @@ -329,9 +329,13 @@ async def set_number( key: str, temperature: float, ) -> None: - """Set the max. Boiler or DHW setpoint on the Central Heating boiler.""" + """Set the maximum boiler- or DHW-setpoint on the Central Heating boiler or the temperature-offset on a Thermostat.""" await self._smile_api.set_number(dev_id, key, temperature) + async def set_temperature_offset(self, dev_id: str, offset: float) -> None: + """Set the Temperature offset for thermostats that support this feature.""" + await self._smile_api.set_offset(dev_id, offset) # pragma: no cover + async def set_switch_state( self, appl_id: str, members: list[str] | None, model: str, state: str ) -> None: diff --git a/plugwise/legacy/smile.py b/plugwise/legacy/smile.py index 24761a9da..7658c6e16 100644 --- a/plugwise/legacy/smile.py +++ b/plugwise/legacy/smile.py @@ -162,6 +162,9 @@ async def set_number( ) -> None: """Set-function placeholder for legacy devices.""" + async def set_offset(self, dev_id: str, offset: float) -> None: + """Set-function placeholder for legacy devices.""" + async def set_preset(self, _: str, preset: str) -> None: """Set the given Preset on the relevant Thermostat - from DOMAIN_OBJECTS.""" if (presets := self._presets()) is None: