Add support of RGB lights (#120)

* Make set_dps available.

* Adding RGB support, brightness fix, color_temp range.

* Update README for light options

* Formatting

* Formatting

* Need to force to white to ensure color picker is updated.

* Detect color mode RGB/HSV based on color length.

* Extract rgb encoded color check in method.

* Make check method private.

* Fix exception when color is not available (maybe when powered off)

* Reformat.
This commit is contained in:
ultratoto14
2020-10-28 09:54:54 +01:00
committed by GitHub
parent d783293a21
commit 657850e39c
6 changed files with 129 additions and 32 deletions

View File

@@ -13,6 +13,8 @@ CONF_BRIGHTNESS_LOWER = "brightness_lower"
CONF_BRIGHTNESS_UPPER = "brightness_upper"
CONF_COLOR = "color"
CONF_COLOR_MODE = "color_mode"
CONF_COLOR_TEMP_MIN_KELVIN = "color_temp_min_kelvin"
CONF_COLOR_TEMP_MAX_KELVIN = "color_temp_max_kelvin"
# switch
CONF_CURRENT = "current"