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
147 stars 34 forks source link

More info on NR messages output by device nodes #364

Closed Alloc86 closed 3 months ago

Alloc86 commented 3 months ago

Hi Massimo,

another thing I brought up before on the forum but probably got forgotten :)

Is your feature request related to a problem? Please describe. No actual problem, but I have to add this to a lot of places myself and I think it could be useful for others too.

Describe the solution you'd like Currently device nodes output information on the GA like this: Property "msg.devicename":

First of all I think it would be nice if the format of that property would be the same in both cases.

Furthermore though I would love to see a new property added. Something like "msg.gainfo" that would contain data like the following:

That way you would not have to add the parsing each time you need individual parts of that data and also probably be less heavy on CPU as you wouldn't have to do the regex magic yourself - and it would work on both standard and universal mode.

This is how I currently do it behind a universal node: image

Supergiovane commented 3 months ago

Hi yes, that is well known, but at this time, i've a little to no time to add features, because i'm focused on the knx engine. I'll leave this issue open for now.

Supergiovane commented 3 months ago

Hi About "devicename" behaviour, i cannot change it, because it's consolidate and many users rely on that. If the node is in universal mode, the devicename is taken from the ETS file, otherwise is taken from the "name" property set in the config window. Not all users have access to the ETS file. The behaviour is, therefore, not the same for all setups. But i can add the msg.gainfo thing in the upcoming release.

Alloc86 commented 3 months ago

Ah, that makes sense. I thought it was actually adding the devicename from the GA's data from ETS, but instead I was actually assigning it "myself" as when I set the GA I always click on the result in the GA dropdown, so the node automatically sets its name based on the GA at that point :)

I fully understand not wanting to change the devicename for everyone! That's the reason for an additional property, and I hope that will help others too :)

Thanks, Massimo!

Supergiovane commented 3 months ago

Output later today in v. 3.0.0

Alloc86 commented 3 months ago

Thank you, Massimo! Works perfectly :)