Load custom struct from one node recursively #1515
ArthurBerettaVerkor
started this conversation in
Show and tell
Replies: 1 comment 1 reply
-
The code looks good, misses a lot of corner cases. Like renaming of basetypes (MyString = ua.String), optionfields, datatypes that reference them self and complicated datatype relationships. This stuff is not used that widely. All this makes our Never used load_custom_struct, so no glue what it's purpose is. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello all, I made this function to load a custom struct from an OPC-UA server for only one node. I am using it to avoid the
client.load_data_type_definitions()
. I had a hard time with badly configured PLC that contain way too many custom structs to load, when I only needed a few to read.To use it, just pass the node data type and the client to the function:
Here is the script:
Is this function properly implemented, or did I miss something ? One thing I did not understand was the parent gathering in the
asyncua.common.structures104.load_custom_struct
function: why is it present ? And do I need it ?Don't hesitate to correct me as I wish to use this function in production, so all critics are most welcome 😄
Kind regards,
AB
Beta Was this translation helpful? Give feedback.
All reactions