BigED
(BigED)
June 8, 2024, 10:17am
1
Hi folks
I have a bit wired topology:
Aqara T1 → Gledopto GL-C-008P ledstrip controller
And I want to control ledstrip via HA. I want two cases:
Accessing from Aqara T1 side
Aqara T1 is turned on → ledstrip is turning on as well.
Aqara T1 is turned off → ledstrip is turning off as well.
It’s simple and I have no issues here
Aqara T1 is off
Attempt to turn on (or change color) ledstrip → turn on aqara → turn on (and set color) strip
But I can’t handle this attempt as ledstrip has no power
Any solution? Or I had to turn on Aqara and then contol strip?
BigED
(BigED)
June 8, 2024, 3:10pm
2
solved: idea is turn on second device if first is turned on and turn off second device if first is turned off
Yo achive it we need several automations, most of them just rely on device states, but to control aqara based on events for ledstrip we need mqtt trigger like this:
alias: livingroom.stripswitch_on
description: ""
trigger:
- platform: mqtt
topic: zigbee2mqtt/livingroom.light.strip.1/set
- platform: mqtt
topic: zigbee2mqtt/livingroom.light.strip.2/set
condition:
- condition: device
type: is_off
device_id: de9bdf625444814485f41672a6fd3d1f
entity_id: 8998a194a48d9c6149d85269e241b162
domain: switch
- condition: template
value_template: "{{ trigger.payload_json['state'] == 'ON' }}"
enabled: true
action:
- type: turn_on
device_id: de9bdf625444814485f41672a6fd3d1f
entity_id: 8998a194a48d9c6149d85269e241b162
domain: switch
mode: single