@@ -192,7 +192,7 @@ def _device_data_adam(
192192 """Helper-function for _get_device_data().
193193
194194 Determine Adam heating-status for on-off heating via valves,
195- and available regulations_modes.
195+ available regulations_modes and thermostat control_states .
196196 """
197197 if not self .smile (ADAM ):
198198 return device_data
@@ -210,6 +210,13 @@ def _device_data_adam(
210210 device_data ["regulation_modes" ] = self ._reg_allowed_modes
211211 self ._count += 1
212212
213+ # Control_state, only for Adam master thermostats
214+ if device ["dev_class" ] in ZONE_THERMOSTATS :
215+ loc_id = device ["location" ]
216+ if ctrl_state := self ._control_state (loc_id ):
217+ device_data ["control_state" ] = ctrl_state
218+ self ._count += 1
219+
213220 return device_data
214221
215222 def _device_data_climate (
@@ -235,11 +242,6 @@ def _device_data_climate(
235242 device_data ["select_schedule" ] = sel_schedule
236243 self ._count += 2
237244
238- # Control_state, only for Adam master thermostats
239- if ctrl_state := self ._control_state (loc_id ):
240- device_data ["control_state" ] = ctrl_state
241- self ._count += 1
242-
243245 # Operation modes: auto, heat, heat_cool, cool and off
244246 device_data ["mode" ] = "auto"
245247 self ._count += 1
@@ -338,7 +340,7 @@ def _get_device_data(self, dev_id: str) -> DeviceData:
338340 device_data ["sensors" ]["outdoor_temperature" ] = outdoor_temperature
339341 self ._count += 1
340342
341- # Show the allowed dhw_modes
343+ # Show the allowed dhw_modes (Loria only)
342344 if device ["dev_class" ] == "heater_central" and self ._dhw_allowed_modes :
343345 device_data ["dhw_modes" ] = self ._dhw_allowed_modes
344346 self ._count += 1
0 commit comments