Difference between revisions of "RRM 3-14 Select"

From EPICSWIKI
 
(Link fields are modifyable)
 
(2 intermediate revisions by 2 users not shown)
Line 21: Line 21:
=== Scan Parameters ===
=== Scan Parameters ===


The select record has the standard fields for specifying under what circumstances the record will be processed. These fields are listed in [[RRM 3-13 dbCommon#Scan Fields|Scan Fields]]. In addition, [[RRM 3-13 Concepts#Scanning Specification|Scanning Specification]] explains how these fields work.
The select record has the standard fields for specifying under what circumstances the record will be processed. These fields are listed in [[RRM 3-14 dbCommon#Scan Fields|Scan Fields]]. In addition, [[RRM 3-14 Concepts#Scanning Specification|Scanning Specification]] explains how these fields work.


=== Read Parameters ===
=== Read Parameters ===


The INPA-L links determine where the selection record retrieves the values from which it is to select or compute its final value. The INPA-L links are input links configured by the user to be either constants, channel access links, or database links. If channel access or database links, a value is retrieved for each link and placed in the corresponding value field, A-L. If any input link is a constant, the value field for that link will be initialized with the constant value given to it and can be modified via dbPuts. See [[RRM 3-13 Concepts#Address Specification|Address Specification]] for information on how to specify database links.
The INPA-L links determine where the selection record retrieves the values from which it is to select or compute its final value. The INPA-L links are input links configured by the user to be either constants, channel access links, or database links. If channel access or database links, a value is retrieved for each link and placed in the corresponding value field, A-L. If any input link is a constant, the value field for that link will be initialized with the constant value given to it and can be modified via dbPuts. See [[RRM 3-14 Concepts#Address Specification|Address Specification]] for information on how to specify database links.


Any links not defined are ignored by the selection record and its algorithm. An undefined link is any constant link whose value is 0. At initialization time, the corresponding value links for such fields are set equal to le30, which means MISSING. The value field of an undefined link can be changed at run-time from the MISSING value to another value in order to define the link and its field. Note that all undefined links must be recognized as such if the selection algorithm is to work as expected.
Any links not defined are ignored by the selection record and its algorithm. An undefined link is any constant link whose value is 0. At initialization time, the corresponding value links for such fields are set to NaN, which means MISSING. The value field of an undefined link can be changed at run-time from NaN to another value in order to define the link and its field. Note that all undefined links must be recognized as such if the selection algorithm is to work as expected.




<TABLE BORDER="1">
<TABLE BORDER="1">
<TH>Field<TH>Summary<TH>Type<TH>DCT<TH>Initial<TH>Access<TH>Modify<TH>Rec Proc Monitor<TH>PP<TR>
<TH>Field<TH>Summary<TH>Type<TH>DCT<TH>Initial<TH>Access<TH>Modify<TH>Rec Proc Monitor<TH>PP<TR>
<TD>INPA<TD>Input A<TD>INLINK<TD>Yes<TD>0<TD>No<TD>No<TD>N/A<TD>No<TR>
<TD>INPA<TD>Input A<TD>INLINK<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>INPB<TD>Input B<TD>INLINK<TD>Yes<TD>0<TD>No<TD>No<TD>N/A<TD>No<TR>
<TD>INPB<TD>Input B<TD>INLINK<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>INPC<TD>Input C<TD>INLINK<TD>Yes<TD>0<TD>No<TD>No<TD>N/A<TD>No<TR>
<TD>INPC<TD>Input C<TD>INLINK<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>INPD<TD>Input D<TD>INLINK<TD>Yes<TD>0<TD>No<TD>No<TD>N/A<TD>No<TR>
<TD>INPD<TD>Input D<TD>INLINK<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>INPE<TD>Input E<TD>INLINK<TD>Yes<TD>0<TD>No<TD>No<TD>N/A<TD>No<TR>
<TD>INPE<TD>Input E<TD>INLINK<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>INPF<TD>Input F<TD>INLINK<TD>Yes<TD>0<TD>No<TD>No<TD>N/A<TD>No<TR>
<TD>INPF<TD>Input F<TD>INLINK<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>INPG<TD>Input G<TD>INLINK<TD>Yes<TD>0<TD>No<TD>No<TD>N/A<TD>No<TR>
<TD>INPG<TD>Input G<TD>INLINK<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>INPH<TD>Input H<TD>INLINK<TD>Yes<TD>0<TD>No<TD>No<TD>N/A<TD>No<TR>
<TD>INPH<TD>Input H<TD>INLINK<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>INPI<TD>Input I <TD>INLINK<TD>Yes<TD>0<TD>No<TD>No<TD>N/A<TD>No<TR>
<TD>INPI<TD>Input I <TD>INLINK<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>INPJ<TD>Input J<TD>INLINK<TD>Yes<TD>0<TD>No<TD>No<TD>N/A<TD>No<TR>
<TD>INPJ<TD>Input J<TD>INLINK<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>INPK<TD>Input K<TD>INLINK<TD>Yes<TD>0<TD>No<TD>No<TD>N/A<TD>No<TR>
<TD>INPK<TD>Input K<TD>INLINK<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>INPL<TD>Input L<TD>INLINK<TD>Yes<TD>0<TD>No<TD>No<TD>N/A<TD>No<TR>
<TD>INPL<TD>Input L<TD>INLINK<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>A<TD>Input A Value<TD>DOUBLE<TD>No<TD>0<TD>Yes<TD>Yes/No<TD>Yes<TD>Yes<TR>
<TD>A<TD>Input A Value<TD>DOUBLE<TD>No<TD>0<TD>Yes<TD>Yes/No<TD>Yes<TD>Yes<TR>
<TD>B<TD>Input B Value<TD>DOUBLE<TD>No<TD>0<TD>Yes<TD>Yes/No<TD>Yes<TD>Yes<TR>
<TD>B<TD>Input B Value<TD>DOUBLE<TD>No<TD>0<TD>Yes<TD>Yes/No<TD>Yes<TD>Yes<TR>
Line 63: Line 63:
The selection algorithm is determined by three fields configurable by the user: the select mechanism (SELM) field, the select number (SELN) field, and the index value location (NVL) field.
The selection algorithm is determined by three fields configurable by the user: the select mechanism (SELM) field, the select number (SELN) field, and the index value location (NVL) field.


The SELM field has four choices, i.e., four algorithms: <CODE>Specified</CODE>, <CODE>High Signal</CODE>, <CODE>Low Signal</CODE>, and <CODE>Median Signal</CODE>. The selection record's VAL field is determined differently for each algorithm. For <CODE>Specified</CODE>, the VAL field is set equal to the value field (A, B, C, D, E, F, G, H, I, J, K, or L) specified by the SELN field. The SELN field contains a number from 0-11 which corresponds to the value field to be used (0 means use A; 1 means use B, etc.). How the NVL field is configured determines, in turn, SELN's value. NVL is an input link from which a value for SELN can be retrieved, Like most other input links NVL can be a constant, or a channel access or database link. If NVL is a link, SELN is retrieved from the location in NVL. If a constant, SELN is initialized to the value given to the constant and can be changed via dbPuts. See [[RRM 3-13 Concepts#Address Specification|Address Specification]] for information on how to specify database links.
The SELM field has four choices, i.e., four algorithms: <CODE>Specified</CODE>, <CODE>High Signal</CODE>, <CODE>Low Signal</CODE>, and <CODE>Median Signal</CODE>. The selection record's VAL field is determined differently for each algorithm. For <CODE>Specified</CODE>, the VAL field is set equal to the value field (A, B, C, D, E, F, G, H, I, J, K, or L) specified by the SELN field. The SELN field contains a number from 0-11 which corresponds to the value field to be used (0 means use A; 1 means use B, etc.). How the NVL field is configured determines, in turn, SELN's value. NVL is an input link from which a value for SELN can be retrieved, Like most other input links NVL can be a constant, or a channel access or database link. If NVL is a link, SELN is retrieved from the location in NVL. If a constant, SELN is initialized to the value given to the constant and can be changed via dbPuts. See [[RRM 3-14 Concepts#Address Specification|Address Specification]] for information on how to specify database links.


The <CODE>High Signal</CODE>, <CODE>Low Signal</CODE>, and <CODE>Median Signal</CODE> algorithms do not use SELN or NVL. If <CODE>High Signal</CODE> is chosen, VAL is set equal to the highest value out of all the defined value fields (A-F). If <CODE>Low Signal</CODE> is chosen, VAL is set equal to lowest value of all the defined fields (A-F). And if <CODE>Median Signal</CODE> is chosen, VAL is set equal to the median value of the defined value fields (A-F). (Note that these algorithms select from the value fields; they do not select from the value field index. For instance, <CODE>Low Signal</CODE> will not select the A field's value unless the value itself is the lowest of all the defined values.)
The <CODE>High Signal</CODE>, <CODE>Low Signal</CODE>, and <CODE>Median Signal</CODE> algorithms do not use SELN or NVL. If <CODE>High Signal</CODE> is chosen, VAL is set equal to the highest value out of all the defined value fields (A-L). If <CODE>Low Signal</CODE> is chosen, VAL is set equal to lowest value of all the defined fields (A-L). And if <CODE>Median Signal</CODE> is chosen, VAL is set equal to the median value of the defined value fields (A-L). (Note that these algorithms select from the value fields; they do not select from the value field index. For instance, <CODE>Low Signal</CODE> will not select the A field's value unless the value itself is the lowest of all the defined values.)




<TABLE BORDER="1">
<TABLE BORDER="1">
<TH>Field<TH>Summary<TH>Type<TH>DCT<TH>Initial<TH>Access<TH>Modify<TH>Rec Proc Monitor<TH>PP<TR>
<TH>Field<TH>Summary<TH>Type<TH>DCT<TH>Initial<TH>Access<TH>Modify<TH>Rec Proc Monitor<TH>PP<TR>
<TD>SELM<TD>Select Mechanism<TD>[[RRM 3-13 Menu Choices|RECCHOICE]]<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>SELM<TD>Select Mechanism<TD>[[RRM 3-14 Menu Choices|RECCHOICE]]<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>SELN<TD>Select Number<TD>USHORT<TD>No<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>SELN<TD>Select Number<TD>USHORT<TD>No<TD>0<TD>Yes<TD>Yes<TD>No<TD>No<TR>
<TD>NVL<TD>Index Value Location, an input link<TD>INLINK<TD>Yes<TD>0<TD>No<TD>No<TD>N/A<TD>No
<TD>NVL<TD>Index Value Location, an input link<TD>INLINK<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No
</TABLE>
</TABLE>


Line 86: Line 86:
The PREC field determines the floating point precision with which to display VAL. It is used whenever the <CODE>get_precision</CODE> record support routine is called.
The PREC field determines the floating point precision with which to display VAL. It is used whenever the <CODE>get_precision</CODE> record support routine is called.


See [[RRM 3-13 dbCommon#Fields Common to All Record Types|Fields Common to All Record Types]] for more on the record name (NAME) and description (DESC) fields.  
See [[RRM 3-14 dbCommon#Fields Common to All Record Types|Fields Common to All Record Types]] for more on the record name (NAME) and description (DESC) fields.  




Line 102: Line 102:
=== Alarm Parameters ===
=== Alarm Parameters ===


The possible alarm conditions for select records are the SCAN, READ, and limit alarms. The SCAN and READ alarms are called by the record or device support routines. The limit alarms are configured by the user in the HIHI, LOLO, HIGH, and LOW fields using numerical values. They specify conditions for the VAL field. For each of these fields, there is a corresponding severity field which can be either NO_ALARM, MINOR, or MAJOR. See [[RRM 3-13 Concepts#Alarm Specification|Alarm Specification]] for a complete explanation of alarms and these fields. [[RRM 3-13 dbCommon#Alarm Fields|Alarm Fields]] lists other fields related to a alarms that are common to all record types.
The possible alarm conditions for select records are the SCAN, READ, and limit alarms. The SCAN and READ alarms are called by the record or device support routines. The limit alarms are configured by the user in the HIHI, LOLO, HIGH, and LOW fields using numerical values. They specify conditions for the VAL field. For each of these fields, there is a corresponding severity field which can be either NO_ALARM, MINOR, or MAJOR. See [[RRM 3-14 Concepts#Alarm Specification|Alarm Specification]] for a complete explanation of alarms and these fields. [[RRM 3-14 dbCommon#Alarm Fields|Alarm Fields]] lists other fields related to a alarms that are common to all record types.




Line 111: Line 111:
<TD>LOW<TD>Low Alarm Limit<TD>FLOAT<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>Yes<TR>
<TD>LOW<TD>Low Alarm Limit<TD>FLOAT<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>Yes<TR>
<TD>LOLO<TD>Lolo Alarm Limit<TD>FLOAT<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>Yes<TR>
<TD>LOLO<TD>Lolo Alarm Limit<TD>FLOAT<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>Yes<TR>
<TD>HHSV<TD>Hihi Alarm Severity<TD>[[RRM 3-13 Menu Choices|GBLCHOICE]]<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>Yes<TR>
<TD>HHSV<TD>Hihi Alarm Severity<TD>[[RRM 3-14 Menu Choices|GBLCHOICE]]<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>Yes<TR>
<TD>HSV<TD>High Alarm Severity<TD>[[RRM 3-13 Menu Choices|GBLCHOICE]]<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>Yes<TR>
<TD>HSV<TD>High Alarm Severity<TD>[[RRM 3-14 Menu Choices|GBLCHOICE]]<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>Yes<TR>
<TD>LSV<TD>Low Alarm Severity<TD>[[RRM 3-13 Menu Choices|GBLCHOICE]]<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>Yes<TR>
<TD>LSV<TD>Low Alarm Severity<TD>[[RRM 3-14 Menu Choices|GBLCHOICE]]<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>Yes<TR>
<TD>LLSV<TD>Lolo Alarm Severity<TD>[[RRM 3-13 Menu Choices|GBLCHOICE]]<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>Yes<TR>
<TD>LLSV<TD>Lolo Alarm Severity<TD>[[RRM 3-14 Menu Choices|GBLCHOICE]]<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>Yes<TR>
<TD>HYST<TD>Alarm Deadband<TD>DOUBLE<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No
<TD>HYST<TD>Alarm Deadband<TD>DOUBLE<TD>Yes<TD>0<TD>Yes<TD>Yes<TD>No<TD>No
</TABLE>
</TABLE>
Line 121: Line 121:
=== Monitor Parameters ===
=== Monitor Parameters ===


These fields are configurable by the user. They are used as deadbands for the archiver and monitor calls for the VAL field. Unless, VAL changes by more than the value specified by each, then the respective monitors will not be called. If these fields have a value of zero, everytime the VAL changes, monitors are triggered; if they have a value of -1, everytime the record is processed, monitors are triggered.  [[RRM 3-13 Concepts#Monitor Specification|Monitor Specification]] gives a complete explanation of alarms and deadbands.
These fields are configurable by the user. They are used as deadbands for the archiver and monitor calls for the VAL field. Unless, VAL changes by more than the value specified by each, then the respective monitors will not be called. If these fields have a value of zero, everytime the VAL changes, monitors are triggered; if they have a value of -1, everytime the record is processed, monitors are triggered.  [[RRM 3-14 Concepts#Monitor Specification|Monitor Specification]] gives a complete explanation of alarms and deadbands.




Line 137: Line 137:
The VAL field is the result of the selection record's processing. It can be accessed in the normal way by another record or through database access, but is not modifiable except by the record itself. The LALM, ALST, and the MLST are used to implement the HYST, ADEL, and MDEL hysteresis factors for the alarms, archiver, and monitors, respectively.
The VAL field is the result of the selection record's processing. It can be accessed in the normal way by another record or through database access, but is not modifiable except by the record itself. The LALM, ALST, and the MLST are used to implement the HYST, ADEL, and MDEL hysteresis factors for the alarms, archiver, and monitors, respectively.


The LA-LL fields are used to implement the monitors for each of the value fields, A-F. They represent previous input values. For example, unless LA is not equal to A, no monitor is invoked for A.
The LA-LL fields are used to implement the monitors for each of the value fields, A-L. They represent previous input values. For example, unless LA is not equal to A, no monitor is invoked for A.




Line 169: Line 169:
IF NVL is a constant, SELN is set to its value. If NVL is a PV_LINK a channel access link is created.
IF NVL is a constant, SELN is set to its value. If NVL is a PV_LINK a channel access link is created.


For each constant input link, the corresponding value field is initialized with the constant value (or 1e30 if the constant has the value 0).
For each constant input link, the corresponding value field is initialized with the constant value (or NaN if the constant has the value 0).


For each input link that is of type PV_LINK, a channel access link is created.
For each input link that is of type PV_LINK, a database or channel access link is created.


==== process ====
==== process ====
Line 220: Line 220:
#* NSEV and NSTA are reset to 0.
#* NSEV and NSTA are reset to 0.
# Scan forward link if necessary, set PACT FALSE, and return.
# Scan forward link if necessary, set PACT FALSE, and return.
----
EPICS Record Reference Manual - 19 MAY 1998

Latest revision as of 19:39, 22 March 2016

EPICS Record Reference Manual


sel - Select

The select record computes a value based on input obtained from up to 12 locations. The selection algorithm can be one of the following: Specified, High Signal, Low Signal, Median Signal. Each input can be a constant, a database link, or a channel access link.

Parameter Fields

The fields in this record fall into several categories:

  • scan parameters
  • read parameters
  • select parameters
  • operator display parameters
  • alarm parameters
  • monitor parameters
  • run-time parameters

Scan Parameters

The select record has the standard fields for specifying under what circumstances the record will be processed. These fields are listed in Scan Fields. In addition, Scanning Specification explains how these fields work.

Read Parameters

The INPA-L links determine where the selection record retrieves the values from which it is to select or compute its final value. The INPA-L links are input links configured by the user to be either constants, channel access links, or database links. If channel access or database links, a value is retrieved for each link and placed in the corresponding value field, A-L. If any input link is a constant, the value field for that link will be initialized with the constant value given to it and can be modified via dbPuts. See Address Specification for information on how to specify database links.

Any links not defined are ignored by the selection record and its algorithm. An undefined link is any constant link whose value is 0. At initialization time, the corresponding value links for such fields are set to NaN, which means MISSING. The value field of an undefined link can be changed at run-time from NaN to another value in order to define the link and its field. Note that all undefined links must be recognized as such if the selection algorithm is to work as expected.


FieldSummaryTypeDCTInitialAccessModifyRec Proc MonitorPP
INPAInput AINLINKYes0YesYesNoNo
INPBInput BINLINKYes0YesYesNoNo
INPCInput CINLINKYes0YesYesNoNo
INPDInput DINLINKYes0YesYesNoNo
INPEInput EINLINKYes0YesYesNoNo
INPFInput FINLINKYes0YesYesNoNo
INPGInput GINLINKYes0YesYesNoNo
INPHInput HINLINKYes0YesYesNoNo
INPIInput I INLINKYes0YesYesNoNo
INPJInput JINLINKYes0YesYesNoNo
INPKInput KINLINKYes0YesYesNoNo
INPLInput LINLINKYes0YesYesNoNo
AInput A ValueDOUBLENo0YesYes/NoYesYes
BInput B ValueDOUBLENo0YesYes/NoYesYes
CInput C ValueDOUBLENo0YesYes/NoYesYes
DInput D ValueDOUBLENo0YesYes/NoYesYes
EInput E ValueDOUBLENo0YesYes/NoYesYes
FInput F ValueDOUBLENo0YesYes/NoYesYes
GInput G ValueDOUBLENo0YesYes/NoYesYes
HInput H ValueDOUBLENo0YesYes/NoYesYes
IInput I ValueDOUBLENo0YesYes/NoYesYes
JInput J ValueDOUBLENo0YesYes/NoYesYes
KInput K ValueDOUBLENo0YesYes/NoYesYes
LInput L ValueDOUBLENo0YesYes/NoYesYes


Select Parameters

The selection algorithm is determined by three fields configurable by the user: the select mechanism (SELM) field, the select number (SELN) field, and the index value location (NVL) field.

The SELM field has four choices, i.e., four algorithms: Specified, High Signal, Low Signal, and Median Signal. The selection record's VAL field is determined differently for each algorithm. For Specified, the VAL field is set equal to the value field (A, B, C, D, E, F, G, H, I, J, K, or L) specified by the SELN field. The SELN field contains a number from 0-11 which corresponds to the value field to be used (0 means use A; 1 means use B, etc.). How the NVL field is configured determines, in turn, SELN's value. NVL is an input link from which a value for SELN can be retrieved, Like most other input links NVL can be a constant, or a channel access or database link. If NVL is a link, SELN is retrieved from the location in NVL. If a constant, SELN is initialized to the value given to the constant and can be changed via dbPuts. See Address Specification for information on how to specify database links.

The High Signal, Low Signal, and Median Signal algorithms do not use SELN or NVL. If High Signal is chosen, VAL is set equal to the highest value out of all the defined value fields (A-L). If Low Signal is chosen, VAL is set equal to lowest value of all the defined fields (A-L). And if Median Signal is chosen, VAL is set equal to the median value of the defined value fields (A-L). (Note that these algorithms select from the value fields; they do not select from the value field index. For instance, Low Signal will not select the A field's value unless the value itself is the lowest of all the defined values.)


FieldSummaryTypeDCTInitialAccessModifyRec Proc MonitorPP
SELMSelect MechanismRECCHOICEYes0YesYesNoNo
SELNSelect NumberUSHORTNo0YesYesNoNo
NVLIndex Value Location, an input linkINLINKYes0YesYesNoNo


Operator Display Parameters

These parameters are used to present meaningful data to the operator. They display the value and other parameters of the select record either textually or graphically.

EGU is a string of up to 16 characters describing the units that the selection record manipulates. It is retrieved by the get_units record support routine.

The HOPR and LOPR fields set the upper and lower display limits for the VAL, HIHI, HIGH, LOW, and LOLO fields. Both the get_graphic_double and get_control_double record support routines retrieve these fields.

The PREC field determines the floating point precision with which to display VAL. It is used whenever the get_precision record support routine is called.

See Fields Common to All Record Types for more on the record name (NAME) and description (DESC) fields.


FieldSummaryTypeDCTInitialAccessModifyRec Proc MonitorPP
EGUEngineering UnitsSTRING [16]YesnullYesYesNoNo
HOPRHigh Operating RangeFLOATYes0YesYesNoNo
LOPRLow Operating RangeFLOATYes0YesYesNoNo
PRECDisplay PrecisionSHORTYes0YesYesNoNo
NAMERecord NameSTRING [29]Yes0YesNoNo 
DESCDescriptionSTRING [29]YesNullYesYesNoNo


Alarm Parameters

The possible alarm conditions for select records are the SCAN, READ, and limit alarms. The SCAN and READ alarms are called by the record or device support routines. The limit alarms are configured by the user in the HIHI, LOLO, HIGH, and LOW fields using numerical values. They specify conditions for the VAL field. For each of these fields, there is a corresponding severity field which can be either NO_ALARM, MINOR, or MAJOR. See Alarm Specification for a complete explanation of alarms and these fields. Alarm Fields lists other fields related to a alarms that are common to all record types.


FieldSummaryTypeDCTInitialAccessModifyRec Proc MonitorPP
HIHIHihi Alarm LimitFLOATYes0YesYesNoYes
HIGHHigh Alarm LimitFLOATYes0YesYesNoYes
LOWLow Alarm LimitFLOATYes0YesYesNoYes
LOLOLolo Alarm LimitFLOATYes0YesYesNoYes
HHSVHihi Alarm SeverityGBLCHOICEYes0YesYesNoYes
HSVHigh Alarm SeverityGBLCHOICEYes0YesYesNoYes
LSVLow Alarm SeverityGBLCHOICEYes0YesYesNoYes
LLSVLolo Alarm SeverityGBLCHOICEYes0YesYesNoYes
HYSTAlarm DeadbandDOUBLEYes0YesYesNoNo


Monitor Parameters

These fields are configurable by the user. They are used as deadbands for the archiver and monitor calls for the VAL field. Unless, VAL changes by more than the value specified by each, then the respective monitors will not be called. If these fields have a value of zero, everytime the VAL changes, monitors are triggered; if they have a value of -1, everytime the record is processed, monitors are triggered. Monitor Specification gives a complete explanation of alarms and deadbands.


FieldSummaryTypeDCTInitialAccessModifyRec Proc MonitorPP
ADELArchive DeadbandDOUBLEYes0YesYesNoNo
MDELMonitor, i.e. value change, DeadbandDOUBLEYes0YesYesNoNo


Run-time Parameters

These parameters are used by the run-time code for processing the selection record. They are not configurable prior to run-time, nor are they modifiable at run-time. They represent the current state of the record. The record support routines use some of them for more efficient processing.

The VAL field is the result of the selection record's processing. It can be accessed in the normal way by another record or through database access, but is not modifiable except by the record itself. The LALM, ALST, and the MLST are used to implement the HYST, ADEL, and MDEL hysteresis factors for the alarms, archiver, and monitors, respectively.

The LA-LL fields are used to implement the monitors for each of the value fields, A-L. They represent previous input values. For example, unless LA is not equal to A, no monitor is invoked for A.


FieldSummaryTypeDCTInitialAccessModifyRec Proc MonitorPP
VALValue FieldDOUBLENo0YesNoYesNo
LALMLast Alarmed Value DOUBLENo0YesNoNoNo
ALST Archive Last ValueDOUBLENo0YesNoNoNo
MLSTMonitor Last Value DOUBLENo0YesNoNoNo
LALast A ValueDOUBLENo0YesNoNoNo
LBLast B ValueDOUBLENo0YesNoNoNo
LCLast C ValueDOUBLENo0YesNoNoNo
LDLast D ValueDOUBLENo0YesNoNoNo
LELast E ValueDOUBLENo0YesNoNoNo
LFLast F ValueDOUBLENo0YesNoNoNo
LGLast G ValueDOUBLENo0YesNoNoNo
LHLast H ValueDOUBLENo0YesNoNoNo
LILast I ValueDOUBLENo0YesNoNoNo
LJLast J ValueDOUBLENo0YesNoNoNo
LKLast K ValueDOUBLENo0YesNoNoNo
LLLast L ValueDOUBLENo0YesNoNoNo


Record Support

Record Support Routines

init_record

IF NVL is a constant, SELN is set to its value. If NVL is a PV_LINK a channel access link is created.

For each constant input link, the corresponding value field is initialized with the constant value (or NaN if the constant has the value 0).

For each input link that is of type PV_LINK, a database or channel access link is created.

process

See next section.

get_value

Fills in the values of struct valueDes so that they refer to VAL.

get_units

Retrieves EGU.

get_precision

Retrieves PREC.

get_graphic_double

Sets the upper display and lower display limits for a field. If the field is VAL, HIHI, HIGH, LOW, or LOLO, the limits are set to HOPR and LOPR, else if the field has upper and lower limits defined they will be used, else the upper and lower maximum values for the field type will be used.

get_control_double

Sets the upper control and the lower control limits for a field. If the field is VAL, HIHI, HIGH, LOW, or LOLO, the limits are set to HOPR and LOPR, else if the field has upper and lower limits defined they will be used, else the upper and lower maximum values for the field type will be used.

get_alarm_double

Sets the following values:

upper_alarm_limit = HIHI
upper_warning_limit = HIGH
lower_warning_limit = LOW
lower_alarm_limit = LOLO


Record Processing

Routine process implements the following algorithm:

  1. If NVL is a database or channel access link, SELN is obtained from NVL. Fetch all values if database or channel access links. If SELM is SELECTED, then only the selected link is fetched.
  2. Implement the appropriate selection algorithm. For SELECT_HIGH, SELECT_LOW, and SELECT_MEDIAN, input fields are ignored if they are undefined. If success, UDF is set to FALSE.
  3. Check alarms. This routine checks to see if the new VAL causes the alarm status and severity to change. If so, NSEV, NSTA, and LALM are set. It also honors the alarm hysteresis factor (HYST). Thus the value must change by more than HYST before the alarm status and severity is lowered.
  4. Check to see if monitors should be invoked.
    • Alarm monitors are invoked if the alarm status or severity has changed.
    • Archive and value change monitors are invoked if ADEL and MDEL conditions are met
    • Monitors for A-L are checked whenever other monitors are invoked
    • NSEV and NSTA are reset to 0.
  5. Scan forward link if necessary, set PACT FALSE, and return.