AlarmInst

Description:              This function returns the instance of the alarm statement in one of the four alarm lists.

Returns:                    An alarm instance

Usage:                       Script or Steady State

Format:                      AlarmInst(List, N, LowLevel, HighLevel, LowCategory, HighCategory)

Parameters:             List   { numeric }  { required }  { no default: }

                                                Any numeric expression giving the list number to search for the alarm. The valid list numbers are:

List

Alarm List

0

Logged alarm list

1

Active alarm list

2

Unacknowledged alarm list

3

Current alarm list

 

                             You may add any of the following numbers to the specified list number to filter the selected list.

List

Attributes

4

Use combined alarm list

8

Don't include alarm occurrences in list

16

Don't include alarm clears in list

32

Don't include alarm acknowledges in list

64

Don't include alarm enables in list

128

Don't include alarm disables in list

 

                             N   { numeric }  { required }  { no default: }

                                                Any numeric expression giving the number of the entry in the list, excluding the entries that do not fall within the bounds specified by the following parameters. This number starts at 1.

                                    LowLevel   { numeric }  { required }  { no default: }

                                                Any numeric expression giving the lower limit for the alarm priority level. If the alarm level is strictly below this value, the alarm is not included in the count specified by the N parameter.

                                    HighLevel   { numeric }  { required }  { no default: }

                                                Any numeric expression giving the upper limit for the alarm priority level. If the alarm level is strictly above this value, the alarm is not included in the count specified by the N parameter.

                                    LowCategory   { numeric }  { required }  { no default: }

                                      Any numeric expression giving the lower limit for the alarm category. If the alarm category is strictly below this value, the alarm is not included in the count specified by the N parameter.

                                    HighCategory { numeric }  { required }  { no default: }

                                                Any numeric expression giving the upper limit for the alarm category. If the alarm category is strictly above this value, the alarm is not included in the count specified by the N parameter.

Comments:               AlarmInst returns the instance where an alarm exists, giving the list containing the alarm, and the entry number of the alarm that falls within the level and category bounds. If there are fewer entries in the list than specified by N, AlarmInst returns Invalid.

Example:

alarmPtr = AlarmInst(1  { Active alarm list },

                     1  { Get first alarm in list },

                     2  { Lowest priority level desired },

                     3  { Highest priority level desired },

                     8  { Lowest category desired },

                     12  { Highest category desired });

In the above example, AlarmPtr is set Invalid if there are no alarm instances that have priority levels of 2 or 3, and categories of 8 to 12; otherwise AlarmPtr is set to the instance for the first alarm (chronologically earliest) where the alarm statement exists.

See Also:

Alarm | AlarmCat | AlmAck | AlmAckID | AlmArray | AlmCatName | AlmColor | AlmEnable | AlmList | AlmTone | NumAlarm