OPC UA, wait what why?
Posted on 21 August, 2022
OPC UA, known as the Open Platform Communications United Architecture is a data exchanged standard used in industrial automation and communication. It communicates by PC-to-machine communication or machine-to-machine communication. OPC UA allows any vendor to develop software and applications that share data in a fast and robust way.
Not to be mistaken with OPC DA, OPC UA does not rely heavily on Windows DCOM (Distributed Component Object Model), is firewall-friendly while addressing security concerns by providing a suite of controls, therefore, making it an open standard.
The standard that govern information model associated with programs in the OPC UA is IEC 62541, or also known as open62541.
Features of OPC UA include:
- Platform independence: OPC UA is platform independent. It can be supported on high-end servers and low-end sensors and from an embedded micro-controller to cloud-based infrastructure.
- Security: encryption, authentication, and auditing
- Extensibility: ability to add new features without affecting existing applications
- Comprehensive information modeling: for defining complex information. The OPC UA address space is organized around the concept of an object. Objects are entities that consist of variables and methods and provide a standard way for servers to transfer information to clients.
- On-demand: read and write data/information based on access-permissions
- Subscriptions: monitor data/information and report-by-exception when values change based on a client’s criteria
- Events: notify important information based on client’s criteria
- Methods: clients can execute programs, etc. based on methods defined on the server
some random information: Did you know, any product being advertised as "Industry 4.0-enabled" must be OPC UA-capable? Yup and this could be either through integration or a gateway.
Information Modeling and Access
The OPC UA information modeling framework turns data into information. With complete object-oriented capabilities, even the most complex multi-level structures can be modeled and extended.
This framework is THE fundamental element of OPC Unified Architecture. It defines the rules and base building blocks necessary to expose an information model with OPC UA. While OPC UA already defines several core models that can be applied in many industries, other organizations build their models upon them, exposing their more specific information with OPC UA.
OPC UA also defines the necessary access mechanisms to information models.
- Look-up mechanism (browsing) to locate instances and their semantic
- Read and write operations for current data and historical data
- Method execution
- Notification for data and events
The OPC UA framework supports the client/server services and protocols and publish/subscribe (PubSub) models and protocols. OPC UA can run on a dedicated client and server relationship. In the PubSub scenario, the server sends (publishes) data to the network, and the client (who subscribed) will receive the data.
For Client-Server communication the full range of information model access is available via services and in doing so follows the design paradigm of service-oriented architecture (SOA), with which a service provider receives requests, processes them and sends the results back with the response.
Publish-Subscribe (PubSub), provides an alternative mechanism for data and event notification. While in Client-Server communication each notification is for a single client with guaranteed delivery, PubSub has been optimized for many-to-many configurations.
With PubSub, OPC UA applications do not directly exchange requests and responses. Instead, Publishers send messages to a Message Oriented Middleware, without knowledge of what, if any, Subscribers there may be. Similarly, Subscribers express interest in specific types of data, and process messages that contain this data, without a need to know where it originated from. PubSubConnections can be created and deleted on runtime.
It is important to note that in the OPC UA specification, authentication, signing, and encryption of data are heavily emphasized for both the client/server and PubSub models.
If you would like to expand more on this content, here is a link to a practical introduction to OPC UA.
I'll talk about data types, OOP and packages separately soon.
Till then, cheers x