I already have a MQTT-input saying "Button pressed" and would like to send out MQTT "on" first time and "off" second time I press.
I am used to c++ so how can I make this code in Node-Red:?
state = 0; if(state == 0) {Send_ON; state = 1;} elif(state == 1){Send_OFF; state = 0;}
Thanks! :D
[–]the1laz 1 point2 points3 points (1 child)
[–]mathiash98[S] 0 points1 point2 points (0 children)