简体   繁体   中英

Eclipse Milo: How to define Complex Datatypes?

I am currently implementing a server to emulate a PLC. The connection to this PLC is done via OPC-UA. The interface is provided by a thrid party and contains several custom datatypes.

Examples:

[Point]
Int32 x
Int32 y

[PhysicalObject]
Int32 id
String name
Point location

(both Point and PhysicalObject are datatypes)

Is it possible to define such structures in Milo, both client and server? I could not find anything related in the examples. I already had a look over the sources, it seems that at least the foundations are there. But being new to OPC UA it is not so easy to figure out if how it is supposed to work.

With the 0.2 release it's possible to define structures for use when both the client and server know about them ahead of time. It's not yet possible to define structures that are discoverable by independent clients.

The 0.3 release series will focus on the server SDK, and allowing the import of an XML NodeSet is on the TODO list. This will allow you to use a modeling tool such as UaModeler to define your structured types, export the model to XML, and then import that model into the server. This is important because the modeling tool will generate the content of the DataTypeDictionary that describes your custom types, which is what allows a client without advanced knowledge to discover and decode these custom structures.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM