Hello! I have a mqtt light that only allows brightness control. If you set the brightness to zero, it will turn off. If you set any non-zero - turn on. With this configuration, everything works successfully:
mqtt:
light:
- name: EcoDimG0
brightness_command_topic: "/devices/ecodim_dali_gw2_21/controls/Group 0 Brightness/on"
brightness_state_topic: "/devices/ecodim_dali_gw2_21/controls/Group 0 Brightness"
state_topic: "/devices/ecodim_dali_gw2_21/controls/Group 0 Brightness"
command_topic: "/devices/ecodim_dali_gw2_21/controls/Group 0 Brightness/on"
on_command_type: brightness
state_value_template: >
{% if value|int > 0 %}1{% else %}0{% endif %}
payload_on: "1"
payload_off: "0"
brightness_scale: 254
But there is one problem. If you turn off the lamp and turn it back on, it will turn on at 100% brightness. Is there any way to make the HA remember the brightness when turned off and restore it when turned on? Thanks in advance!