I have a “smart LED” bulb (AITHINKER
's AI_LIGHT
, but I think this is a broader class of LEDs) which I flashed with ESPurna and presented to HA in configuration.yaml
as (taken from ESPurna interface)
- name: ch2_lampe_pixar
platform: mqtt
state_topic: ch2-lampe-pixar/relay/0
command_topic: ch2-lampe-pixar/relay/0/set
payload_on: 1
payload_off: 0
availability_topic: ch2-lampe-pixar/status
payload_available: 1
payload_not_available: 0
brightness_state_topic: ch2-lampe-pixar/brightness
brightness_command_topic: ch2-lampe-pixar/brightness/set
rgb_state_topic: ch2-lampe-pixar/rgb
rgb_command_topic: ch2-lampe-pixar/rgb/set
color_temp_command_topic: ch2-lampe-pixar/mired/set
white_value_state_topic: ch2-lampe-pixar/channel/3
white_value_command_topic: ch2-lampe-pixar/channel/3/set
I then created two cards for it: a Light
card and an Entity
card:
None of them is perfect: the entity card only allows to switch on and off and the light card acts strange: one cannot switch it on/off by clicking on it, only by sliding the marker around. Then to switch it off I need to use the entity card.
My question: how should such a bulb be configured? Specifically: how to make it appear as a normal lamp (which can be switched on and off), with a settable brightness and colors - in Lovelace?