mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 11:17:21 +00:00
Hound for zwave climate (#4465)
This commit is contained in:
parent
2b5fcd737b
commit
7af438fa2f
@ -104,16 +104,18 @@ class ZWaveClimate(ZWaveDeviceEntity, ClimateDevice):
|
|||||||
_LOGGER.debug("self._current_operation=%s",
|
_LOGGER.debug("self._current_operation=%s",
|
||||||
self._current_operation)
|
self._current_operation)
|
||||||
# Current Temp
|
# Current Temp
|
||||||
for value in (self._node.get_values(
|
for value in (
|
||||||
class_id=zwave.const.COMMAND_CLASS_SENSOR_MULTILEVEL)
|
self._node.get_values(
|
||||||
.values()):
|
class_id=zwave.const.COMMAND_CLASS_SENSOR_MULTILEVEL)
|
||||||
|
.values()):
|
||||||
if value.label == 'Temperature':
|
if value.label == 'Temperature':
|
||||||
self._current_temperature = round((float(value.data)), 1)
|
self._current_temperature = round((float(value.data)), 1)
|
||||||
self._unit = value.units
|
self._unit = value.units
|
||||||
# Fan Mode
|
# Fan Mode
|
||||||
for value in (self._node.get_values(
|
for value in (
|
||||||
class_id=zwave.const.COMMAND_CLASS_THERMOSTAT_FAN_MODE)
|
self._node.get_values(
|
||||||
.values()):
|
class_id=zwave.const.COMMAND_CLASS_THERMOSTAT_FAN_MODE)
|
||||||
|
.values()):
|
||||||
self._current_fan_mode = value.data
|
self._current_fan_mode = value.data
|
||||||
self._fan_list = list(value.data_items)
|
self._fan_list = list(value.data_items)
|
||||||
_LOGGER.debug("self._fan_list=%s", self._fan_list)
|
_LOGGER.debug("self._fan_list=%s", self._fan_list)
|
||||||
@ -121,9 +123,10 @@ class ZWaveClimate(ZWaveDeviceEntity, ClimateDevice):
|
|||||||
self._current_fan_mode)
|
self._current_fan_mode)
|
||||||
# Swing mode
|
# Swing mode
|
||||||
if self._zxt_120 == 1:
|
if self._zxt_120 == 1:
|
||||||
for value in (self._node.get_values(
|
for value in (
|
||||||
class_id=zwave.const.COMMAND_CLASS_CONFIGURATION)
|
self._node.get_values(
|
||||||
.values()):
|
class_id=zwave.const.COMMAND_CLASS_CONFIGURATION)
|
||||||
|
.values()):
|
||||||
if value.command_class == \
|
if value.command_class == \
|
||||||
zwave.const.COMMAND_CLASS_CONFIGURATION and \
|
zwave.const.COMMAND_CLASS_CONFIGURATION and \
|
||||||
value.index == 33:
|
value.index == 33:
|
||||||
@ -134,9 +137,10 @@ class ZWaveClimate(ZWaveDeviceEntity, ClimateDevice):
|
|||||||
self._current_swing_mode)
|
self._current_swing_mode)
|
||||||
# Set point
|
# Set point
|
||||||
temps = []
|
temps = []
|
||||||
for value in (self._node.get_values(
|
for value in (
|
||||||
class_id=zwave.const.COMMAND_CLASS_THERMOSTAT_SETPOINT)
|
self._node.get_values(
|
||||||
.values()):
|
class_id=zwave.const.COMMAND_CLASS_THERMOSTAT_SETPOINT)
|
||||||
|
.values()):
|
||||||
temps.append((round(float(value.data)), 1))
|
temps.append((round(float(value.data)), 1))
|
||||||
if value.index == self._index:
|
if value.index == self._index:
|
||||||
if value.data == 0:
|
if value.data == 0:
|
||||||
@ -149,15 +153,17 @@ class ZWaveClimate(ZWaveDeviceEntity, ClimateDevice):
|
|||||||
else:
|
else:
|
||||||
self._target_temperature = round((float(value.data)), 1)
|
self._target_temperature = round((float(value.data)), 1)
|
||||||
# Operating state
|
# Operating state
|
||||||
for value in (self._node.get_values(
|
for value in (
|
||||||
class_id=zwave.const.COMMAND_CLASS_THERMOSTAT_OPERATING_STATE)
|
self._node.get_values(
|
||||||
.values()):
|
class_id=zwave.const
|
||||||
|
.COMMAND_CLASS_THERMOSTAT_OPERATING_STATE).values()):
|
||||||
self._operating_state = value.data
|
self._operating_state = value.data
|
||||||
|
|
||||||
# Fan operating state
|
# Fan operating state
|
||||||
for value in (self._node.get_values(
|
for value in (
|
||||||
class_id=zwave.const.COMMAND_CLASS_THERMOSTAT_FAN_STATE)
|
self._node.get_values(
|
||||||
.values()):
|
class_id=zwave.const.COMMAND_CLASS_THERMOSTAT_FAN_STATE)
|
||||||
|
.values()):
|
||||||
self._fan_state = value.data
|
self._fan_state = value.data
|
||||||
|
|
||||||
@property
|
@property
|
||||||
|
Loading…
x
Reference in New Issue
Block a user