Represents single Yeelight device.
Definition at line 64 of file device.py.
◆ __init__()
| None homeassistant.components.yeelight.device.YeelightDevice.__init__ |
( |
|
self, |
|
|
HomeAssistant |
hass, |
|
|
str |
host, |
|
|
dict[str, Any] |
config, |
|
|
AsyncBulb
|
bulb |
|
) |
| |
Initialize device.
Definition at line 67 of file device.py.
◆ _active_mode()
| def homeassistant.components.yeelight.device.YeelightDevice._active_mode |
( |
|
self | ) |
|
|
private |
◆ _async_forced_update()
| def homeassistant.components.yeelight.device.YeelightDevice._async_forced_update |
( |
|
self, |
|
|
|
_now |
|
) |
| |
|
private |
Call a forced update.
Definition at line 222 of file device.py.
◆ _async_update_properties()
| def homeassistant.components.yeelight.device.YeelightDevice._async_update_properties |
( |
|
self | ) |
|
|
private |
Read new properties from the device.
Definition at line 172 of file device.py.
◆ _color_flow()
| def homeassistant.components.yeelight.device.YeelightDevice._color_flow |
( |
|
self | ) |
|
|
private |
◆ _nightlight_brightness()
| def homeassistant.components.yeelight.device.YeelightDevice._nightlight_brightness |
( |
|
self | ) |
|
|
private |
◆ async_mark_unavailable()
| def homeassistant.components.yeelight.device.YeelightDevice.async_mark_unavailable |
( |
|
self | ) |
|
Set unavailable on api call failure due to a network issue.
Definition at line 107 of file device.py.
◆ async_setup()
| def homeassistant.components.yeelight.device.YeelightDevice.async_setup |
( |
|
self | ) |
|
Fetch capabilities and setup name if available.
Definition at line 197 of file device.py.
◆ async_update()
| def homeassistant.components.yeelight.device.YeelightDevice.async_update |
( |
|
self, |
|
|
|
force = False |
|
) |
| |
Update device properties and send data updated signal.
Definition at line 214 of file device.py.
◆ async_update_callback()
| def homeassistant.components.yeelight.device.YeelightDevice.async_update_callback |
( |
|
self, |
|
|
|
data |
|
) |
| |
Update push from device.
Definition at line 227 of file device.py.
◆ available()
| def homeassistant.components.yeelight.device.YeelightDevice.available |
( |
|
self | ) |
|
Return true is device is available.
Definition at line 102 of file device.py.
◆ bulb()
| def homeassistant.components.yeelight.device.YeelightDevice.bulb |
( |
|
self | ) |
|
Return bulb device.
Definition at line 82 of file device.py.
◆ config()
| def homeassistant.components.yeelight.device.YeelightDevice.config |
( |
|
self | ) |
|
Return device config.
Definition at line 92 of file device.py.
◆ fw_version()
| def homeassistant.components.yeelight.device.YeelightDevice.fw_version |
( |
|
self | ) |
|
Return the firmware version.
Definition at line 117 of file device.py.
◆ host()
| def homeassistant.components.yeelight.device.YeelightDevice.host |
( |
|
self | ) |
|
Return hostname.
Definition at line 97 of file device.py.
◆ is_color_flow_enabled()
| bool homeassistant.components.yeelight.device.YeelightDevice.is_color_flow_enabled |
( |
|
self | ) |
|
Return true / false if color flow is currently running.
Definition at line 148 of file device.py.
◆ is_nightlight_enabled()
| bool homeassistant.components.yeelight.device.YeelightDevice.is_nightlight_enabled |
( |
|
self | ) |
|
Return true / false if nightlight is currently enabled.
Definition at line 135 of file device.py.
◆ is_nightlight_supported()
| bool homeassistant.components.yeelight.device.YeelightDevice.is_nightlight_supported |
( |
|
self | ) |
|
Return true / false if nightlight is supported.
Uses brightness as it appears to be supported in both ceiling and other lights.
Definition at line 127 of file device.py.
◆ model()
| def homeassistant.components.yeelight.device.YeelightDevice.model |
( |
|
self | ) |
|
Return configured/autodetected device model.
Definition at line 112 of file device.py.
◆ name()
| def homeassistant.components.yeelight.device.YeelightDevice.name |
( |
|
self | ) |
|
Return the name of the device if any.
Definition at line 87 of file device.py.
◆ type()
| def homeassistant.components.yeelight.device.YeelightDevice.type |
( |
|
self | ) |
|
◆ unique_id()
| str | None homeassistant.components.yeelight.device.YeelightDevice.unique_id |
( |
|
self | ) |
|
Return the unique ID of the device.
Definition at line 122 of file device.py.
◆ _available
| homeassistant.components.yeelight.device.YeelightDevice._available |
|
private |
◆ _bulb_device
| homeassistant.components.yeelight.device.YeelightDevice._bulb_device |
|
private |
◆ _config
| homeassistant.components.yeelight.device.YeelightDevice._config |
|
private |
◆ _device_type
| homeassistant.components.yeelight.device.YeelightDevice._device_type |
|
private |
◆ _hass
| homeassistant.components.yeelight.device.YeelightDevice._hass |
|
private |
◆ _host
| homeassistant.components.yeelight.device.YeelightDevice._host |
|
private |
◆ _initialized
| homeassistant.components.yeelight.device.YeelightDevice._initialized |
|
private |
◆ _name
| homeassistant.components.yeelight.device.YeelightDevice._name |
|
private |
◆ capabilities
| homeassistant.components.yeelight.device.YeelightDevice.capabilities |
The documentation for this class was generated from the following file:
- core/homeassistant/components/yeelight/device.py