-
Notifications
You must be signed in to change notification settings - Fork 98
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to subscribe to an ExtensionObject or nested value array #171
Comments
Hello, you can see the implementation in the TestClient project, and the implementation of the subscription for the server in the TestServer project. |
Hello, Can you capture subscribing via uaexpert in Wireshark with no security and share that here? I would guess it subscribed to something besides (nodeid, value). |
Hi Nauful, sure, I've capture the traffic from UAExpert and the LibUA client for the mentioned node, which is now ns=4;i=2801; after an structure update on the OPC server. The according dump is named after that at the end (..._libua / ..._uaexpert). What I've seen so far, the requests are nearly the same for the specific node, but in the LibUA client, the "NotifyDataChangeNotifications" method is not fired on an publish response for that node. Maybe there is some filter or switch case missing in LibUA? opc_nodeid_subscribe_libua.zip |
Hmm, it looks like that should have worked. Please check this line and step through to see if it reaches the call to LibUA/NET Core/LibUA/Client.cs Line 4294 in 34253aa
If decoding succeeds, it should call LibUA/NET Core/TestClient/Program.cs Line 98 in 34253aa
|
Thanks for the hint. I've stepped through the code and found the failing part in the Client.cs on line 4299, where the call Maybe the ExtensionObject has a different mask and need to be handle separately in the MemoryBufferExtensions.cs? |
Thanks, that gives me a hint. Let me investigate. I don't think I've seen an extension object in a variant before so this is a new case. |
Fixed, let me know if the latest version works. |
Looks good, great work 👍 . The only thing that seems to be missing is the source timestamp, the server timestamp is correct in the notification. Maybe another bug? |
Okay that was my fault, sorry for that 👍 . Thanks again for the fast response and quick fix, everything is working now like expected :-) |
Hi Nauful,
I'm trying to subscribe to an ExtensionObject, which contains two sub-levels of value arrays, without success actually. I'm note sure, if it is even possible, since in the opc ua specification is written: Objects and views can be used to monitor Events Ref.
Why I'm asking, if I subscribe to that specific node id in UAExpert from UnifiedAutomation, the Source and Server Timestamp is updated all the time on any value change in the sub tree of that node. If I subscribe, with NodeAttribute.Value, to that specific node in LibUA, nothing happens. Also UAExperts tell me, it's an mentioned ExtensionObject.
Can you tell me what I'm missing or is it a feature that is still not implemented in LibUA?
Here is an picture of the attributes of that specific node, which shows the sub-levels of the value arrays:

The text was updated successfully, but these errors were encountered: