Hi,
Is there a way to keep two switches in sync? Without creating 4 rules?
greetings
Gear
How to sync two switches?
Hi,
Is there a way to keep two switches in sync? Without creating 4 rules?
greetings
Gear
If they are doing the same-use just one
What kind of switches?
Gruß M.
One mqtt Switch and one Dummy Switch.
If you have 2 mqtt-switches, you could´t use the same State Topic, but a Dummy-Switch has no State-Topic.
Whats the reason for this?
i want to toggle the dummy switch by amazon echo and the dummy switch should toggle the mqtt switch
When $dummy.state changes then toggle mqtt
Do you really want toggle?
Do you have a better idea?
When $dummy.state changes then toggle mqtt
With this rule, it would be possible to switch mqtt switches without toggle dummy switch. I wanted to avoid that.
Other ideas?
@gear1900
But if you only toggle the actual value of the mqtt-swich is no matter because every change of the dummy switch reversed the mqtt-switch.
@gear1900
is the dummy switch only for the echo ? you can export the mqtt switch directly to alexa.
to sync to buttons you need two rules.
rule1: if button1 is turn on or button2 is turn on then switch button1 on and switch button2 on
rule2: if button1 is turn off or button2 is turn off then switch button1 off and switch button2 off
I don´t know why you need 2 Switches. You can switch the mqtt-switch with alexa.
What is the reason for the dummy?
OK. What’s about Shell Switches?
Also have this problem often but did not find a proper solution yet.
My scenario:
switch1: switches a device on and sets the correct inputs etc
rule1: if switch1 is turned on press buttonToTurnDeviceOn and turn on AvReceiver and press buttonToSelectCorrectInput
But for example the device can also be switched on with the original remote or can be operated with the buttons on the device.
I can for example for one device detect its state with a ping presence but if i simply switch on the device then it would again trigger the rule associated.
rule2: if device is present turn switch1 on
there currently is no way of changing the state without triggering all associated actions/rules
the only way I can think of that you extend the rule for the switch to also look for the condition you use for “on” detection
rule1: if switch1 is turned on and device is not present press buttonToTurnDeviceOn and turn on AvReceiver and press buttonToSelectCorrectInput
however this will only work for a dummy switch in use with rules, if there is a plugin behind it there is no way of preventing the action when changing the state of a switch.
something like the :trigger keyword would be great
if device is present :preventAction turn switch1 on
Why not like this?
rule1: if switch1 is turned on and device XX is not present then press buttonToTurnDeviceOn and turn on AvReceiver and press buttonToSelectCorrectInput
This should be work for you