First I wanted to sync state of button connected to GPIO with switch in domoticz, I followed this thread: https://www.domoticz.com/forum/viewtopic.php?t=18249
I did:
433v1 button is set to push button active lowon 433v1#State do
if [Dummy#State]=1
TaskValueSet 1,1,0
sendtohttp domoticzip,8080,/json.htm?param=switchlight&type=command&idx=27&switchcmd=Off
else
TaskValueSet 1,1,1
SendToHTTP domoticzip,8080,/json.htm?param=switchlight&type=command&idx=27&switchcmd=On
endif
endon
and on domoticz:
On Action: http://espip/control?cmd=taskvalueset,1,1,1
Off Action: http://espip/control?cmd=taskvalueset,1,1,0
And it is working well
Then I want to do some action when dummy state is changing
Nevermind where I'm changing state of dummy (domoticz or button) always I have to wait 30-55s(randomly) for the GPIO state to change.on Dummy#State do
if [Dummy#State]=1
gpio,12,1
gpio,16,1
gpio,13,0
delay,1500
gpio,14,0
else
gpio,13,1
gpio,14,1
gpio,12,0
delay,1500
gpio,16,0
endif
endon
Where is problem?, It should happen immediately...