Page 1 of 1

Switches Looping

Posted: Saturday 28 March 2020 10:21
by levynger
i assume this was asked previously - couldnt find any post on this tough..

Due to last changes in release in MQTT out - no longer broadcasted
i have to create for multiple switches different IDX in domoticz
untill now, 1 switch connected to the light, and other acting as 2/3 ways - so i have used the same IDX for all the siwtches that controls it.
since domoticz/out used to broadcast all changes - it would update the rest of the physical switches.

so to create the same behaviour - i have for example 2 switches - each has different IDX
with LUA/Blocky/DZvent - when one is on or off - i want to update the other one.

in this case - it would create endless loop of On/ Off commands - perhaps due to the fact that the trigger switch yet to be updated in domoticz?

even with 2 seconds delay - i ended in loop ON-Off sequence commands..
Capture.PNG
Capture.PNG (32.12 KiB) Viewed 584 times

Re: Switches Looping

Posted: Saturday 28 March 2020 21:55
by AllesVanZelf
I do no fully understand what you what to achieve, but [else if 1] is actually the same as [else if 2]. So same condition, but conflicting action [On/Off].
These 3 [Else if's] is too much conflict.

Re: Switches Looping

Posted: Sunday 29 March 2020 9:13
by Gerwin
blockly.png
blockly.png (190.98 KiB) Viewed 548 times
i think you are using the wrong time block if you want 2 sec put only 2 in the block
if you are using a block out logic you can't use a block in the same rule out the time

Gerwin