OPC UA & UDP & TSN

Questions regarding the use of the High Perfomance SDK for Server development

Moderator: uasdkhpc

Post Reply
dingyan
Full Member
Full Member
Posts: 9
Joined: 24 Jun 2016, 02:46

OPC UA & UDP & TSN

Post by dingyan »

Hello, support team:

In the Reference Documentation of High performance SDK(SDK Architecture -> SDK Platform Layer Architecture -> Network Module), I notice that you have mentioned about UDP function.

Supporting UDP is a very interesting feature, because in conjunction with TSN(Time Sensitive Network), the OPC UA(UDP) devices will be able to horizontally communicate with each other in real time.

My question is:

1. Is the UDP network layer already implemented in this SDK? If yes, does there exists any UA Client tool(like UaExpert) to interoperate with OPC UA UDP server?

2. According to an online document, the Publisher/Subscriber model is designed for OPC UA, that seems related with UDP multicast protocol and TSN. So my question is what is the relationship between the UDP function in your document and Publisher/Subscriber model?

Regards

User avatar
Support Team
Hero Member
Hero Member
Posts: 3064
Joined: 18 Mar 2011, 15:09

Re: OPC UA & UDP & TSN

Post by Support Team »

Hello dingyan,

UDP is already prepared in our network API, this means it is possible to create UDP sockets and use ua_socket_sendto and ua_socket_recvfrom to send and receive UDP packets (this functionality is beta yet, and not tested).
This is the basis for UDP based protocols like DHCP, DNS, ZeroConf, etc. and of course UA Pub Sub.

UA Pub Sub is not implemented yet. It is also important to note that UA Pub Sub alone does not allow real time communication.
It's just a way for fast periodic data transfer using IP multicasts. This allows you to implement 1:n communication with one sender
and multiple receivers. Despite other PubSub alternatives like MQTT and AMQP the UADP (UDP based UA ) works without a broker in the local subnet.

TSN is another important feature which lays the foundation for real-time communication. But this is far from being complete.
Especially how to configure networks with different TSN devices from different vendors is not specified yet.

So we will first implement non-realtime UA PubSub (UADP), and TSN support will be added later.

regards,
Unified Automation Support Team
Best regards
Unified Automation Support Team

dingyan
Full Member
Full Member
Posts: 9
Joined: 24 Jun 2016, 02:46

Re: OPC UA & UDP & TSN

Post by dingyan »

Hello,

That is great to hear that UDP layer will be supported, and thanks a lot for your quick response.

Based on your reply, please let me ask 2 more questions:

1. Does UADP (UDP based UA ) only means "UA Server with UDP network transport layer", or it means more things like "UDP + PubSub"?

2. OPC UA is currently using an Session/Subscription model(1:1); In contrast of that, most of PubSub brokers(like MQTT) are based on a Topic based design which is totally different. So I wonder how this two kind of mechanism can co-exist in an unified architecture. Does the UA specification Part 4 need to be updated?

Thanks

User avatar
Support Team
Hero Member
Hero Member
Posts: 3064
Joined: 18 Mar 2011, 15:09

Re: OPC UA & UDP & TSN

Post by Support Team »

Hi dingyan,

sorry for the late answer, for some reason I didn't get a notification mail for your last response.

To 1) UADP is the new UDP based OPC UA protocol for PubSub.
The High Perf SDK does not contain UADP, only the UDP protocol which is used as transport for UADP and other protocols
like DNS, ZeroConf, NTP, etc. is there. UDP in the SDK is just a abstract socket API, which hides platform specific function calls.

To 2) PubSub is a complete new communication model (not yet released by the OPCF) that will coexist with the TCP based
client-server model that we use today. PubSub provides a generic information model which can use different existing pub/sub transports
like AMQP. MQTT is also possible. UADP is an own protocol from OPCF for this use case which uses UDP and IP multicasts.
The existing client/server model will still be necessary, e.g. to get the encryption keys for the messages sent via UADP and
to configure what should published. UADP is unreliable due to the nature of UDP, but supports encryption.

Comparision:

UA/TCP:
* 1:1 communication relation
* reliable connection (not data lost)
* only transmits changed data (reduces network load)
* secured by encryption and cryptographic signatures

UADP/UDP:
* 1:n communication relation using IP multicasts
* unreliable (UDP)
* cyclic transfer of configure messages (like field busses)
* can be faster than TCP due to less overhead in the data, but always transfers all data,
so this is only valid we you assume that all monitored data is changing in every cycle
* can reduce network load in 1:n scenarios, where UA/TCP would need to send the data to n times to n clients
* also secured by encryption and cryptographic signatures

So when do you use what? For classic SCADA/HMI use cases as well as for reliable data logging the OPC.TCP protocol is still the best choice.
If you have many applications which are interested only in the latest value and don't care about data loss (e.g. simple displays) UADP can make sense. Also in bad connection scenarios with lots of data loss (e.g. WLAN ) UDP can have advantages, because TCP retransmissions can make things worse if you have already a lots of packet loss.

AMQP based Pub/Sub mainly makes sense if you want to push data into the MS Azure Cloud.

MQTT based Pub/Sub could make sense if you want to connect to any other IOT cloud, which often use MQTT.

So this cloud connectivity is a special use case, which not important for internal locally communication. Also you will not push all data into the cloud, but a subset of information where you to make use of mathematical post-processing of your data (correlation, bigdata, condition monitoring, ...)

TSN may offer hard real-time communication for UA in the future.

regards,
Unified Automation Support Team
Best regards
Unified Automation Support Team

dingyan
Full Member
Full Member
Posts: 9
Joined: 24 Jun 2016, 02:46

Re: OPC UA & UDP & TSN

Post by dingyan »

Hello, support team:

I just see your reply today, thanks for all the details.

Currently, we are developing our SCADA system based on your C++ SDK, and another R&D team of our company is planing to put an OPC UA wrapper into our existing PLC which may be based on ANSI C SDK.

The High Performance SDK is in our future plan, specially for closed-loop control scenario. But now, we still don't have a full picture about the Pub/Sub pattern and TSN, so this plan is just on pre-research phrase.

Thanks again

Post Reply