Supergiovane / node-red-contrib-knx-ultimate

Control your KNX intallation via Node-Red! A bunch of KNX nodes, with integrated Philips HUE control and ETS group address importer.
https://youtu.be/egRbR_KwP9I
MIT License
143 stars 34 forks source link

"Passive" GA only triggers when requested #295

Closed OnkelJudith closed 8 months ago

OnkelJudith commented 8 months ago

Hey there,

first of all: thank you for your amazing project node-red-contrib-knx-ultimate! I have a very special problem where I was not able to solve it by myself. Maybe you could help me out. I want to react to a KNX event triggered by a GA for stopping my window coverings. When the Stop-GA fired, I want to read a second GA with the current value of my window covering. For this use case I need the second GA to only react to my previous event. Current behaviour is, that this node reacts to my event but also fires every time an update an this GA (with the current position) happens. But this destroys my pipeline, because I just want to trigger some actions in case of this stop-event via my first GA.

Is there any way I can tell the KNX device node to only read a value then this read is triggered by my Node-RED pipeline and not every time an update is fired to this GA?

I hope you are able to follow my idea :)

Greetings from Germany Christoph

Supergiovane commented 8 months ago

Hi Christoph yes. You need to uncheck "React to read events" (in the device node config window), and issue this code in a function node msg.readstatus = true. If you post here your flow, i can modify it for you.

Supergiovane commented 8 months ago

There is a sample as well: https://github.com/Supergiovane/node-red-contrib-knx-ultimate/wiki/-Sample---Read-value-from-Device

OnkelJudith commented 8 months ago

Oh this function node made it work, thank you!