diff --git a/Home-Assistant.md b/Home-Assistant.md index d5b76814..543a8b37 100644 --- a/Home-Assistant.md +++ b/Home-Assistant.md @@ -212,20 +212,37 @@ Configure the module as "34 MagicHome" and form the Console run `SetOption15 1`. ```yaml light: - - platform: mqtt - name: bar_leds - state_topic: "stat/sonoff/POWER" - command_topic: "cmnd/sonoff/POWER" - qos: 1 - retain: true - payload_on: "ON" - payload_off: "OFF" - brightness_scale: 100 - brightness_command_topic: "cmnd/sonoff/DIMMER" - brightness_state_topic: "stat/sonoff/RESULT" - brightness_value_template: "{{ value_json.Dimmer }}" - rgb_command_topic: "cmnd/sonoff/COLOR" - rgb_command_template: '{{ "%02x" | format(red|int) }}{{ "%02x" | format(green|int) }}{{ "%02x" | format(blue|int) }}' - rgb_state_topic: "stat/sonoff/RESULT" - rgb_value_template: "{{ value_json.Color[0:2] | int(base=16) }},{{ value_json.Color[2:4] | int(base=16) }},{{ value_json.Color[4:6] | int(base=16) }}" -``` \ No newline at end of file +- platform: mqtt + name: magic + effect_list: + - 0 + - 1 + - 2 + - 3 + - 4 + - 5 + - 6 + - 7 + - 8 + - 9 + - 10 + - 11 + - 12 + state_topic: "cmnd/sonoff/POWER" + command_topic: "cmnd/sonoff/POWER" + brightness_state_topic: "cmnd/sonoff/Dimmer" + brightness_command_topic: "cmnd/sonoff/Dimmer" + brightness_scale: 100 + rgb_command_template: "{{ '%02x%02x%02x' | format(red, green, blue)}}" + rgb_state_topic: "cmnd/sonoff/Color" + rgb_command_topic: "cmnd/sonoff/Color" + effect_command_topic: "cmnd/sonoff/Scheme" + effect_state_topic: "cmnd/sonoff/Scheme" + state_value_template: "{{ value }}" + brightness_value_template: "{{ value }}" + effect_value_template: "{{ value }}" + rgb_command_mode: hex + retain: false + qos: 1 + payload_on: "ON" + payload_off: "OFF"