Avatar

Please consider registering
guest

sp_LogInOut Log In sp_Registration Register

Register | Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed Topic RSS sp_TopicIcon
Listing existing ALARMS on a node
April 15, 2020
16:57, EEST
Avatar
fabien.le-mentec
Member
Members
Forum Posts: 6
Member Since:
February 26, 2020
sp_UserOfflineSmall Offline

Hi,

when a UA client connects, is it possible to list all the active alarms on a node ? UaExpert does so, how does it does ? Is UaClient.readHistoryEvents the right way ?

Thanks for helping

Cheers

April 16, 2020
10:42, EEST
Avatar
Bjarne Boström
Moderator
Moderators
Forum Posts: 983
Member Since:
April 3, 2012
sp_UserOfflineSmall Offline

Hi,

In OPC UA there exists standard Methods for ConditionType named ConditionRefresh (https://reference.opcfoundation.org/v104/Core/docs/Part9/5.5.7/) and ConditionRefresh2 (https://reference.opcfoundation.org/v104/Core/docs/Part9/5.5.8/).

They cause the server to resend events for Conditions (Alarms are Conditions), either on the whole Subscription level (ConditionRefresh) or for a single MonitoredItem (ConditionRefresh2).

You can call them e.g. like this:

try {
client.call(Identifiers.ConditionType, Identifiers.ConditionType_ConditionRefresh,
new Variant[] {new Variant(subscription.getSubscriptionId())});
} catch (Exception e) {
// Handle errors here
}

P.S. Generally I would expect more servers to support ConditionRefresh than ConditionRefresh2, since ConditionRefresh2 is defined in later versions of the specification. Still both do require that the server’s do support them.

April 16, 2020
11:22, EEST
Avatar
fabien.le-mentec
Member
Members
Forum Posts: 6
Member Since:
February 26, 2020
sp_UserOfflineSmall Offline

Hi Bjarne,

thanks a lot for your answer and details, it is exactly what I was looking for.

I understood that readHistoryEvents was not the way to go. After reading the specs, I was looking for a method called ConditionRefresh() in the SDK source code but did not find anything … Don’t you think and would be convenient to wrap the code you provided into a public method in UaClient ?

Cheers,

Fabien.

April 16, 2020
13:28, EEST
Avatar
Bjarne Boström
Moderator
Moderators
Forum Posts: 983
Member Since:
April 3, 2012
sp_UserOfflineSmall Offline

This is at least the intended way by the specification. In theory you probably could get the same info via reading event history, but basically then you would need to filter that by yourself to know which are e.g. active.

We are aware that a helper method for this could be useful. Probably would be more like Subscription.conditionRefresh() and/or MonitoredEventItem.conditionRefresh() when we actually implement it. Generally speaking we are aware of literally 100s of improvements etc. we could do, it is just a matter of how they are prioritized.

Forum Timezone: Europe/Helsinki

Most Users Ever Online: 518

Currently Online:
9 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

hbrackel: 135

pramanj: 86

Francesco Zambon: 81

rocket science: 77

ibrahim: 75

Sabari: 62

kapsl: 57

gjevremovic: 49

Xavier: 43

fred: 41

Member Stats:

Guest Posters: 0

Members: 680

Moderators: 16

Admins: 1

Forum Stats:

Groups: 3

Forums: 15

Topics: 1467

Posts: 6259

Newest Members:

sagarchau, elviralangwell4, Donnavek, Eddiefauth, DonaldPooma, fidelduke938316, Jan-Pfizer, DavidROunc, fen.pang@woodside.com, aytule

Moderators: Jouni Aro: 1009, Otso Palonen: 32, Tuomas Hiltunen: 5, Pyry: 1, Petri: 0, Bjarne Boström: 983, Heikki Tahvanainen: 402, Jukka Asikainen: 1, moldzh08: 0, Jimmy Ni: 26, Teppo Uimonen: 21, Markus Johansson: 42, Niklas Nurminen: 0, Matti Siponen: 321, Lusetti: 0, Ari-Pekka Soikkeli: 5

Administrators: admin: 1