From 8c45ba2a1a3497ac61a82bd07d44bfea10864c91 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A5kan=20=C3=85kerberg?= Date: Mon, 12 Sep 2022 19:19:47 +0200 Subject: [PATCH] 1.0.2 --- custom_components/shelly/__init__.py | 2 +- custom_components/shelly/light.py | 14 ++++++-------- custom_components/shelly/manifest.json | 2 +- 3 files changed, 8 insertions(+), 10 deletions(-) diff --git a/custom_components/shelly/__init__.py b/custom_components/shelly/__init__.py index 8c07c5c..de75307 100755 --- a/custom_components/shelly/__init__.py +++ b/custom_components/shelly/__init__.py @@ -61,7 +61,7 @@ _LOGGER = logging.getLogger(__name__) -__version__ = "1.0.1" +__version__ = "1.0.2" VERSION = __version__ async def async_setup(hass, config): diff --git a/custom_components/shelly/light.py b/custom_components/shelly/light.py index 7033dc6..b852462 100755 --- a/custom_components/shelly/light.py +++ b/custom_components/shelly/light.py @@ -11,9 +11,7 @@ ) from homeassistant.components.light import ( ATTR_BRIGHTNESS, ATTR_COLOR_TEMP, ATTR_EFFECT, ATTR_HS_COLOR, - ATTR_WHITE_VALUE, - SUPPORT_BRIGHTNESS, SUPPORT_COLOR, SUPPORT_COLOR_TEMP, SUPPORT_EFFECT, - SUPPORT_WHITE_VALUE, + SUPPORT_BRIGHTNESS, SUPPORT_COLOR, SUPPORT_COLOR_TEMP, SUPPORT_EFFECT ) from functools import partial from homeassistant.helpers import config_validation as cv, entity_platform, service @@ -231,8 +229,8 @@ def supported_features(self): features = features | SUPPORT_COLOR_TEMP if self._dev.effects_list is not None: features = features | SUPPORT_EFFECT - if self._dev.support_white_value: - features = features | SUPPORT_WHITE_VALUE + #if self._dev.support_white_value: + # features = features | SUPPORT_WHITE_VALUE return features @property @@ -287,9 +285,9 @@ def turn_on(self, **kwargs): brightness = round(kwargs[ATTR_BRIGHTNESS] / 2.55) self._brightness = brightness - if ATTR_WHITE_VALUE in kwargs: - white_value = int(kwargs[ATTR_WHITE_VALUE]) - self._white_value = white_value + #if ATTR_WHITE_VALUE in kwargs: + # white_value = int(kwargs[ATTR_WHITE_VALUE]) + # self._white_value = white_value if ATTR_HS_COLOR in kwargs: red, green, blue = \ diff --git a/custom_components/shelly/manifest.json b/custom_components/shelly/manifest.json index 8a72bc9..96e6cc4 100644 --- a/custom_components/shelly/manifest.json +++ b/custom_components/shelly/manifest.json @@ -1,7 +1,7 @@ { "domain": "shelly", "name": "Shelly smart home", - "version": "1.0.1", + "version": "1.0.2", "config_flow": true, "documentation": "https://github.com/StyraHem/ShellyForHASS/blob/master/README.md", "dependencies": ["zeroconf"],