Node-red-simple-gate help needed for debugging and setup


Hi everyone,
I feel like this is the right place to ask about node-red-simple-gate.
I really like this node for its simplicity and functionality (Thanks drmike)
I am trying to implement my Hikvisions cameras to turn on a led light integrated with homeassistant presence detection and big timer. Big timers triggers perfect the simple gate but I've got no luck with homeassistant event state.
I added two inject nodes and connected them with message node for debugging.
the messages are looking exactly the same with the output of the "Change" node but only the inject nodes are opening the gate. I am digging about a three days in a row what's going on but with no any result. Please if anyone can look at the screenshots and the configuration to point me to my error. Thanks in advance.
[{"id":"3ad3baf7.3a85f6","type":"tab","label":"Flow 3","disabled":false,"info":""},{"id":"1b9cd4b6.16e4bb","type":"server-state-changed","z":"3ad3baf7.3a85f6","name":"At Villa?","server":"6550c169.4f217","entityidfilter":"device_tracker.google_maps_117732613331293269145","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"output_only_on_state_change":true,"x":124.5,"y":277,"wires":[["5382f0e6.47991"]]},{"id":"5382f0e6.47991","type":"change","z":"3ad3baf7.3a85f6","name":"Change","rules":[{"t":"change","p":"payload","pt":"msg","from":"Villa","fromt":"str","to":"open","tot":"str"},{"t":"change","p":"payload","pt":"msg","from":"home","fromt":"str","to":"close","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":427.5,"y":277,"wires":[["fdddc2e.560464","6e6bc24d.7d183c"]]},{"id":"6e6bc24d.7d183c","type":"gate","z":"3ad3baf7.3a85f6","name":"","controlTopic":"control","defaultState":"closed","openCmd":"open","closeCmd":"close","toggleCmd":"toggle","defaultCmd":"default","persist":true,"x":655.5,"y":287,"wires":[[]]},{"id":"f583c990.e047d8","type":"inject","z":"3ad3baf7.3a85f6","name":"Payload: Villa","topic":"control","payload":"Villa","payloadType":"str","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":152.5,"y":371,"wires":[["5382f0e6.47991"]]},{"id":"b8a3363.b6ea3c8","type":"inject","z":"3ad3baf7.3a85f6","name":"Payload: home","topic":"control","payload":"home","payloadType":"str","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":141,"y":429,"wires":[["5382f0e6.47991"]]},{"id":"fdddc2e.560464","type":"debug","z":"3ad3baf7.3a85f6","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":660.5,"y":398,"wires":[]},{"id":"6550c169.4f217","type":"server","z":"","name":"Raspberry Pi Homeassistant","legacy":false,"hassio":false,"rejectUnauthorizedCerts":true,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":true}]


Show us what you see in the debug node for the working and non-working messages.


@dimitar, I'm glad you like the gate node and certainly want it to do the job for you. I think the answer @Colin's question will show us the problem.


I was prepared with a screenshot of the debug output but as a new member I was able to post only one picture.
Here the first couple is from the inject node the second is from the event state output of homeassistant.
Thanks for replying.


The obvious difference is that the topics are different. To make open/close work the topic needs to be whatever you have specified for Control Topic in the gate node setup.


Yep that was the problem @Colin thank you for the reply again I was in a loop for three days.
Yee I am so happy now.!!!!


There had to be a difference in the messages as all a node knows when it is passed a message is what is in the message. Whenever you get a similar situation compare all aspects of the messages. If necessary you can change the debug to show the full message.