OPC-UA StatusCode additional information|OPC UA Standard|Forum|OPC Foundation

Avatar
Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
Lost password?
sp_Feed sp_PrintTopic sp_TopicIcon
OPC-UA StatusCode additional information
Avatar
Joe Riemersma
New Member
Members
Forum Posts: 2
Member Since:
09/14/2021
sp_UserOfflineSmall Offline
1
10/06/2022 - 03:28
sp_Permalink sp_Print sp_EditHistory

I have recently been using an OPC-DA to UA bridge so that I can read values on an OPC-DA server with an OPC-UA client.

When performing a ReadRequest for a value on the server the ReadResponse's result's statusCode returned is 0x000000c0. I believe the bridge is adding the OPC-DA quality code to the additional information bits of the StatusCode. My question is: Is this valid in OPC-UA and compliant with https://reference.opcfoundatio.....t4/7.34.1/?

I am of the understanding that it is not, as the above specification states:

"The complete list of StatusCodes is defined in OPC 10000-6Servers shall not define their own StatusCodes."

and the complete list of status code's does not contain this status code. Additionally, according to Table 175 – StatusCode Bit Assignments, since the InfoType bits are 00, then it states "The info bits are not used and shall be set to zero." but here the info bits are no set to zero.

However, Someone that I have spoken to mentions that this is valid as the specification states:

The bottom 16 bits are bit flags that contain additional information but do not affect the meaning of the StatusCode

and so that makes the StatusCode 0x000000c0 valid since the 16 bottom bits do not affect the meaning of the StausCode and it is "only extra information you can choose to ignore." And so the OPC-DA quality code is added to provide "a precise error description without a conversion".

Would the correct behaviour also be to map the DA quality code to a UA quality code following https://reference.opcfoundatio.....rt8/A.3.2/?

 

Would it be possible to get some clarification on this?

Thanks in advance! 

Avatar
Randy Armstrong
Admin
Forum Posts: 1564
Member Since:
05/30/2017
sp_UserOfflineSmall Offline
2
10/06/2022 - 04:52
sp_Permalink sp_Print

When testing StatusCodes for equality you only look at the top 16 bits.

If you actually use the InfoBits you need to validate them.

Invalid InfoBits cannot be used.

Avatar
Joe Riemersma
New Member
Members
Forum Posts: 2
Member Since:
09/14/2021
sp_UserOfflineSmall Offline
3
10/06/2022 - 05:25
sp_Permalink sp_Print

So does this mean that the bottom 16 bits of the statuscode 0x000000c0 are invalid as per Table 175 – StatusCode Bit Assignments? If so does this invalidate the entire status code or just the additional information bits?

Avatar
Randy Armstrong
Admin
Forum Posts: 1564
Member Since:
05/30/2017
sp_UserOfflineSmall Offline
4
10/06/2022 - 09:24
sp_Permalink sp_Print

The StatusCode can be used in tests for equality or tests for Bad/Good/Uncertain based on the top 16 bits.

You cannot use the InfoBits unless they are valid.

Forum Timezone: America/Phoenix
Most Users Ever Online: 510
Currently Online:
Guest(s) 26
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Forum Stats:
Groups: 2
Forums: 10
Topics: 1435
Posts: 4855