8:22, EET
January 7, 2019
Hi,
I am evaluating Prosys Java SDK client library.
I want to read/write and call method for complex data type value.
Does the Prosys Simulation Server has any node on which i can write complex data type value or a call method which takes complex data type as argument?
Also, does Prosys Java SDK client library support write and call method for complex data type?
Thanks in advance.
13:58, EET
November 28, 2018
Hi,
Prosys OPC UA Java SDK supports Structures (complex types), writing them and having them as method call arguments. In practice, you will need the NodeSet2 XML format model defining your custom types, and then to use our codegen to create the corresponding classes. This is explained in the Java SDK documentation.
Currently, Simulation Server doesn’t unfortunately contain nodes where you could write a Structure or include one as an argument. I suggest you have a look at Unified Automation’s demo servers which do include more Structure examples. You can find the demo servers here: https://www.unified-automation.com/downloads/opc-ua-servers.html
17:04, EET
November 20, 2019
12:48, EET
April 3, 2012
Hi,
For general Write and Call service calls, see the SampleConsoleClient example methods SampleConsoleClient.write and SampleConsoleClient.callMethod and refer to javadocs for the SDK methods called.
Complex types are Structures and can be put into Variants the same way as basic types. Writing NodeSet2 files is outside of the scope of the SDK and can be done e.g. with tools like UaModeler. But once you have the model you can use the codegen that comes with the SDK to make the equivalent classes (see codegen manual for more information and the codegen/commandline/configexamples on how to generate some of the models we bundle, one of which is a SampleTypes model, which I recommend testing first).
Alternatively assuming you have connected to a server that has a custom Structure, you can use UaClient.getTypeDictionary().getStructureSpecification(…) to get a StructureSpecification object, then make a DynamicStructure object by passing that. That is a Structure that can be passed to Variants. For more information see the javadocs of the DynamicStructure.
Most Users Ever Online: 1919
Currently Online:
27 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Heikki Tahvanainen: 402
hbrackel: 144
rocket science: 88
pramanj: 86
Francesco Zambon: 83
Ibrahim: 78
Sabari: 62
kapsl: 57
gjevremovic: 49
Xavier: 43
Member Stats:
Guest Posters: 0
Members: 728
Moderators: 7
Admins: 1
Forum Stats:
Groups: 3
Forums: 15
Topics: 1529
Posts: 6471
Newest Members:
roycedelargie91, kourtneyquisenbe, ellis87832073466, zkxwilliemae, gabriellabachus, Deakin, KTP25Zof, Wojciech Kubala, efrennowell431, wilfredostuartModerators: Jouni Aro: 1026, Pyry: 1, Petri: 0, Bjarne Boström: 1032, Jimmy Ni: 26, Matti Siponen: 349, Lusetti: 0
Administrators: admin: 1