EcoStruxure Geo SCADA Expert Forum
Schneider Electric support forum about installation, configuration, integration and troubleshooting of EcoStruxure Geo SCADA Expert (ClearSCADA, ViewX, WebX).
Link copied. Please paste this link to share this article on your social media post.
Posted: 2024-12-13 04:02 AM
Is there an easy way to accept an alarm in a ST program. We want to use an external source to accept some alarms in our application.
I found in the manual that a method could be used in a ST program. Is this the right way to do this in an ST program and does someone know how to declare and write the accept from the program. I don't get it working propely now.
If there is a better way to do this please let me know.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2024-12-15 03:16 PM . Last Modified: 2024-12-15 03:21 PM
There are a few ways to do this in ST based on which methods you call.
1. Call the .Accept method on the object and this accepts all alarms that are active unaccepted on that object (which for objects that can have multiple alarms this might not be ideal)
2. Call the .Accept method on the alarm subcondition for the object to only accept that specific alarm
3. If you know the alarm cookie, you can use that using the .AcceptAlarmByCookie method on the root group
PROGRAM AcceptAlarms
METHOD
AcceptAll AT %M(.Direct Outstation.Accept); (* Not ideal *)
AcceptSpecific AT %M(.Direct Outstation.DNP3OSConfigCorrupt.Accept); (* Better but makes it object specific *)
AcceptByCookie AT %M(AcceptAlarmByCookie) : DINT, STRING;
END_METHOD
AcceptAll();
AcceptSpecific();
AcceptByCookie(1, 'Test'); (* Need to find the cookie id *)
END_PROGRAM
You can get the subconditions from the schema, depending on how you call the logic you could pass the subscondition in (for example from scripting on the alarm banner), e.g.:
PROGRAM AcceptAlarms
VAR_INPUT
FullName : STRING;
SubCond : STRING;
END_VAR
METHOD
AcceptSpecific AT %M({FullName}.{SubCond}.Accept);
END_METHOD
AcceptSpecific();
END_PROGRAM
Hope that helps.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2024-12-15 03:16 PM . Last Modified: 2024-12-15 03:21 PM
There are a few ways to do this in ST based on which methods you call.
1. Call the .Accept method on the object and this accepts all alarms that are active unaccepted on that object (which for objects that can have multiple alarms this might not be ideal)
2. Call the .Accept method on the alarm subcondition for the object to only accept that specific alarm
3. If you know the alarm cookie, you can use that using the .AcceptAlarmByCookie method on the root group
PROGRAM AcceptAlarms
METHOD
AcceptAll AT %M(.Direct Outstation.Accept); (* Not ideal *)
AcceptSpecific AT %M(.Direct Outstation.DNP3OSConfigCorrupt.Accept); (* Better but makes it object specific *)
AcceptByCookie AT %M(AcceptAlarmByCookie) : DINT, STRING;
END_METHOD
AcceptAll();
AcceptSpecific();
AcceptByCookie(1, 'Test'); (* Need to find the cookie id *)
END_PROGRAM
You can get the subconditions from the schema, depending on how you call the logic you could pass the subscondition in (for example from scripting on the alarm banner), e.g.:
PROGRAM AcceptAlarms
VAR_INPUT
FullName : STRING;
SubCond : STRING;
END_VAR
METHOD
AcceptSpecific AT %M({FullName}.{SubCond}.Accept);
END_METHOD
AcceptSpecific();
END_PROGRAM
Hope that helps.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2024-12-16 01:34 AM
Thanks Adam, made a mistake in the declaration!
Link copied. Please paste this link to share this article on your social media post.
Create your free account or log in to subscribe to the board - and gain access to more than 10,000+ support articles along with insights from experts and peers.