diff --git a/homeassistant/components/light/zwave.py b/homeassistant/components/light/zwave.py index 5d0b334aeee..f71dd158f61 100644 --- a/homeassistant/components/light/zwave.py +++ b/homeassistant/components/light/zwave.py @@ -115,7 +115,6 @@ class ZwaveDimmer(zwave.ZWaveDeviceEntity, Light): zwave.ZWaveDeviceEntity.__init__(self, value, DOMAIN) self._brightness = None self._state = None - self.update_properties() self._alt_delay = None self._zw098 = None @@ -134,6 +133,8 @@ class ZwaveDimmer(zwave.ZWaveDeviceEntity, Light): " %s", value.parent_id) self._alt_delay = 1 + self.update_properties() + # Used for value change event handling self._refreshing = False self._timer = None @@ -222,17 +223,12 @@ class ZwaveColorLight(ZwaveDimmer): self._rgb = None self._ct = None - # Here we attempt to find a zwave color value with the same instance - # id as the dimmer value. Currently zwave nodes that change colors - # only include one dimmer and one color command, but this will - # hopefully provide some forward compatibility for new devices that - # have multiple color changing elements. + # Currently zwave nodes only exist with one color element per node. for value_color in value.node.get_rgbbulbs().values(): - if value.instance == value_color.instance: - self._value_color = value_color + self._value_color = value_color if self._value_color is None: - raise ValueError("No matching color command found.") + raise ValueError("No color command found.") for value_color_channels in value.node.get_values( class_id=zwave.const.COMMAND_CLASS_SWITCH_COLOR,