* Add WLED integration * Use f-string for uniq id in sensor platform * Typing improvements * Removes sensor & light platform * Remove PARALLEL_UPDATES from integration level * Correct type in code comment 'themselves' * Use async_track_time_interval in async context * Remove stale code * Remove decorator from Flow handler * Remove unused __init__ from config flow * Move show form methods to sync * Only wrap lines that can raise in try except block * Remove domain and platform from uniq id * Wrap light state in bool object in is_on method * Use async_schedule_update_ha_state in async context * Return empty dict in device state attributes instead of None * Remove unneeded setdefault call in setup entry * Cancel update timer on entry unload * Restructure config flow code * Adjust tests for new uniq id * Correct typo AdGuard Home -> WLED in config flow file comment * Convert internal package imports to be relative * Reformat JSON files with Prettier * Improve tests based on review comments * Add test for zeroconf when no data is provided * Cleanup and extended tests
25 lines
617 B
Python
25 lines
617 B
Python
"""Constants for the WLED integration."""
|
|
|
|
# Integration domain
|
|
DOMAIN = "wled"
|
|
|
|
# Hass data keys
|
|
DATA_WLED_CLIENT = "wled_client"
|
|
DATA_WLED_TIMER = "wled_timer"
|
|
DATA_WLED_UPDATED = "wled_updated"
|
|
|
|
# Attributes
|
|
ATTR_COLOR_PRIMARY = "color_primary"
|
|
ATTR_DURATION = "duration"
|
|
ATTR_IDENTIFIERS = "identifiers"
|
|
ATTR_INTENSITY = "intensity"
|
|
ATTR_MANUFACTURER = "manufacturer"
|
|
ATTR_MODEL = "model"
|
|
ATTR_ON = "on"
|
|
ATTR_PALETTE = "palette"
|
|
ATTR_PLAYLIST = "playlist"
|
|
ATTR_PRESET = "preset"
|
|
ATTR_SEGMENT_ID = "segment_id"
|
|
ATTR_SOFTWARE_VERSION = "sw_version"
|
|
ATTR_SPEED = "speed"
|
|
ATTR_TARGET_BRIGHTNESS = "target_brightness"
|