mikakaraila / node-red-contrib-opcua

A Node-RED node to communicate OPC UA. Uses node-opcua library.
Other
212 stars 196 forks source link

OPC UA Node identifier #683

Closed johnbarbosas closed 3 months ago

johnbarbosas commented 5 months ago

Hello there, idk if it's an issue, but how can I access the OPC UA nodes using a string identifier, instead of using the number ID? Cause when edit my AAS on AAS Package Explorer and export this as a nodeset, the ID number changes every time, so even though I make a table including names and IDs, I need do remake this table every time I make a change on AAS.

mikakaraila commented 5 months ago

I added this feature to read, which action needs this?

image

image

Code will detect that msg is not containing nodeId, it will translate browsePath back to nodeId and use it then... should be compatible with existing flows.

johnbarbosas commented 4 months ago

Thank you so much! I'll try it.

johnbarbosas commented 4 months ago

I've already updated the pallete, and tried a lot of things, but always get the same error:

"warning: properties like messageType, namespace, variableName or VariableValue is missing."

I use this command: br=/0:Objects/6:AASROOT/6:AssetAdministrationShell:myStation1/6:Submodel:Handling2/6:Feedback/6:Q_94_Claw_2_Cart/6:Value

Idk, but I think numbers refers to namespace and names refers to BrowserName/DisplayName (tried both, didn't worked).

image

mikakaraila commented 4 months ago

Should work as I have tested with Prosys UA Simulation server this: image

mikakaraila commented 4 months ago

Sorry there was typo in verbose logging... fixed to next version

mikakaraila commented 4 months ago

Please test, I just published new version

johnbarbosas commented 3 months ago

It worked, thxx!! Soon I'm gonna post here my flow for other ones who want to do the same thing.