BiancoRoyal / node-red-contrib-iiot-opcua

deprecated - very new developed by PLUS for Node-RED - https://plus4nodered.com
https://www.npmjs.com/package/node-red-contrib-iiot-opcua
BSD 3-Clause "New" or "Revised" License
34 stars 9 forks source link

No datapoint info inside a subscribed event #10

Closed deminngi closed 6 years ago

deminngi commented 6 years ago

Hi Klaus,

I am testing an injector with two data points connected to a listener that itself is connected to an OPC/UA server. After the injector is started I see two subscribed data points. So far so good.

If I trigger a change of value I get the following data structure:

{"value":{"dataType":"Boolean","arrayType":"Scalar","value":false},"statusCode":{"value":0,"description":"No Error","name":"Good"},"sourceTimestamp":"2018-02-22T14:58:11.260Z","sourcePicoseconds":0,"serverTimestamp":"2018-02-22T14:58:11.721Z","serverPicoseconds":0}

My goal is to use your multi node capability to reduce the amount of flows to be created.

What I need is the corresponding data point, description that triggered this event.

How can I get this info bound to the event?

... and what is meta inject, multi node option means for the listener node?

biancode commented 6 years ago

Hi Giovanni,

did you check the msg object?

image

biancode commented 6 years ago

and you get a message per monitored object / nodeId

biancode commented 6 years ago

and the result filter could pick up what you are searching for ...

image

biancode commented 6 years ago

The Meta Inject was an idea to take care about sending some meta data to react (read, write ...) on events, but I found no time to finish that. It is inactive for now.

deminngi commented 6 years ago

I cannot see the payload mentioned before

image
biancode commented 6 years ago

Switch the debug node to msg and not just msg.payload ;)

Sent with GitHawk