Refactor Tradfri constants (#27334)
* Refactor constants * Rename constant * Rename constant * Rename constant * Review update * Remove duplicate constant * Reorder constants * Dont refresh features * Order package imports * Fix bug * Put back features in refresh * Fix import order * Refactor supported features * Refactor supported features, take 2
This commit is contained in:
parent
a8db8d8c0b
commit
78e9bba279
8 changed files with 73 additions and 69 deletions
|
@ -1,7 +1,25 @@
|
|||
"""Consts used by Tradfri."""
|
||||
from homeassistant.components.light import SUPPORT_TRANSITION, SUPPORT_BRIGHTNESS
|
||||
from homeassistant.const import CONF_HOST # noqa pylint: disable=unused-import
|
||||
|
||||
CONF_IMPORT_GROUPS = "import_groups"
|
||||
ATTR_DIMMER = "dimmer"
|
||||
ATTR_HUE = "hue"
|
||||
ATTR_SAT = "saturation"
|
||||
ATTR_TRADFRI_GATEWAY = "Gateway"
|
||||
ATTR_TRADFRI_GATEWAY_MODEL = "E1526"
|
||||
ATTR_TRADFRI_MANUFACTURER = "IKEA"
|
||||
ATTR_TRANSITION_TIME = "transition_time"
|
||||
CONF_ALLOW_TRADFRI_GROUPS = "allow_tradfri_groups"
|
||||
CONF_IDENTITY = "identity"
|
||||
CONF_KEY = "key"
|
||||
CONF_IMPORT_GROUPS = "import_groups"
|
||||
CONF_GATEWAY_ID = "gateway_id"
|
||||
CONF_KEY = "key"
|
||||
CONFIG_FILE = ".tradfri_psk.conf"
|
||||
DEFAULT_ALLOW_TRADFRI_GROUPS = False
|
||||
DOMAIN = "tradfri"
|
||||
KEY_API = "tradfri_api"
|
||||
KEY_GATEWAY = "tradfri_gateway"
|
||||
KEY_SECURITY_CODE = "security_code"
|
||||
SUPPORTED_GROUP_FEATURES = SUPPORT_BRIGHTNESS | SUPPORT_TRANSITION
|
||||
SUPPORTED_LIGHT_FEATURES = SUPPORT_TRANSITION
|
||||
TRADFRI_DEVICE_TYPES = ["cover", "light", "sensor", "switch"]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue