1 """Support for LIFX lights."""
3 from __future__
import annotations
5 from aiolifx
import products
11 from .const
import DOMAIN
12 from .coordinator
import LIFXUpdateCoordinator
16 """Representation of a LIFX entity with a coordinator."""
18 _attr_has_entity_name =
True
20 def __init__(self, coordinator: LIFXUpdateCoordinator) ->
None:
21 """Initialise the light."""
23 self.
bulbbulb = coordinator.device
25 identifiers={(DOMAIN, coordinator.serial_number)},
26 connections={(dr.CONNECTION_NETWORK_MAC, coordinator.mac_address)},
28 name=coordinator.label,
29 model=products.product_map.get(self.
bulbbulb.product,
"LIFX Bulb"),
30 sw_version=self.
bulbbulb.host_firmware_version,
31 suggested_area=self.
bulbbulb.group,
None __init__(self, LIFXUpdateCoordinator coordinator)