EPICS Record Reference Manual
The record supports alarm limits, conversion from/to engineering units, and graphics and control limits. The analog output fields fall into the following categories:
scan parameters
desired output parameters
convert and write parameters
operator display parameters
alarm parameters
monitor parameters
run-time parameters.
closed_loop
or supervisory
. If supervisory
is specified, the value in the VAL field can be set externally via
dbPuts at run-time. If closed_loop
is specified, the VAL
field's value is obtained from the address specified in the desired
output location field (DOL), which can be either a database link or a
channel access link. To achieve continuous control, a database link to a
control algorithm record should be entered in the DOL field.
When VAL is obtained from DOL, the OIF field decides whether the value
obtained from DOL is an increment to be added to the current VAL or if
the value obtained from DOL is the actual value. The OIF field has two
choices, Incremental
or Full
. The OIF and OMSL
fields, in addition to being configurable, can also be changed during
run-time. (OIF is not used when OMSL is set to SUPERVISORY.)
The VAL field's value is forced to be within the limits specified in the fields DRVH and DRVL, which are configured by the designer:
DRVL<=VAL<=DRVH
Note: If nothing is entered for DRVH and DRVL, the output value will never change. |
Soft
Channel
device support is specified, the value in OVAL is sent
to the address in the OUT field. Otherwise, a conversion process is
performed. The next section on convert and write parameters explains how
this value is converted before being written.See Address Specification, Chapter 1, 2, for information on specifying links. Scanning Specification, Chapter 1, 1, explains the effect of database linkage on scanning.
Field | Summary | Type | DCT | Initial | Access | Modify | Rec Proc Monitor | PP |
---|---|---|---|---|---|---|---|---|
OMSL | Output Mode Select | GBLCHOICE | Yes | 0 | Yes | Yes | No | No |
DOL | Desired Output Location (an Input Link) | INLINK | Yes | 0 | No | No | N/A | No |
OIF | Out Full or Incremental | RECCHOICE | Yes | 0 | Yes | Yes | No | No |
DRVH | Drive High | FLOAT | Yes | 0 | Yes | Yes | No | Yes |
DRVL | Drive Low | FLOAT | Yes | 0 | Yes | Yes | No | Yes |
VAL | Value | DOUBLE | No | 0 | Yes | Yes | Yes | Yes |
OROC | Maximum Output Rate of Change | FLOAT | Yes | 0 | Yes | Yes | No | No |
OVAL | Output Value | DOUBLE | No | 0 | Yes | Yes | Yes | No |
Soft Channel
device support routine, the specified conversions (if any) are performed
on the OVAL field and the resulting value in the RVAL field is sent to
the address contained in the output link after it is adjusted by the
values in the AOFF and ASLO fields.
Field | Summary | Type | DCT | Initial | Access | Modify | Rec Proc Monitor | PP |
---|---|---|---|---|---|---|---|---|
OUT | Output Link | OUTLINK | Yes | 0 | No | No | N/A | No |
DTYP | Device Type | DEVCHOICE | Yes | 0 | Yes | No | No | |
LINR | Type of Conversion | CVTCHOICE | Yes | 0 | Yes | Yes | No | Yes |
RVAL | Raw Value | LONG | No | 0 | Yes | Yes | Yes | Yes |
ROFF | Raw Value Offset | LONG | No | 0 | Yes | Yes | No | Yes |
EGUF | Engineering Units Full | FLOAT | Yes | 0 | Yes | Yes | No | Yes |
EGUL | Engineering Units Low | FLOAT | Yes | 0 | Yes | Yes | No | Yes |
AOFF | Adjustment Offset | FLOAT | Yes | 0 | Yes | Yes | No | Yes |
ASLO | Adjustment Slope | FLOAT | Yes | 1 | Yes | Yes | No | Yes |
ESLO | Slope for Linear Conversions | DOUBLE | No | 1 | Yes | No | No | No |
Soft Channel
device
support, the LINR field determines if a conversion is performed and
which conversion algorithm is used to convert OVAL to RVAL. The LINR
field can specify LINEAR for linear conversions, NO CONVERSION for no
conversions at all, or the name of a breakpoint table such as typeKdegC
for breakpoint conversions.
Note that the ESLO, EGUF, and EGUL fields are only used for linear
conversions. Also note that none of these fields have any significance
for records that use the Soft Channel
device support
module.
ROFF | Computed by device support
routines. Used to offset raw value. Used by all records but Soft
Channel records. |
EGUF | The user must calculate these fields when configuring the database. They are used to calculate the value ESLO, and are thus only significant for records that use linear conversions. See Conversion Specification, Chapter 1, 3, for more information on how to calculate these fields. |
EGUL | |
AOFF | These fields are adjustment parameters for the raw output values. They are applied to the raw output value after conversion from engineering units. |
ASLO | |
ESLO | Computed by device support using EGUF and EGUL. Used if LINR specifies LINEAR. |
To see how the Raw Soft Channel
device support routine uses
these fields, see Section 11.3, Device
Support For Soft Records, in this chapter for more information.
dbst
utility in R3.13.For soft records the output link can be a database link, a channel access link, or a constant value. If the link is a constant, no output is sent. See Address Specification, Chapter 1, 2, for information on the format of database and channel access addresses.
EGU is a string of up to 16 characters describing the units that the analog output measures. 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, OVAL, PVAL, HIHI, HIGH, LOW, and LOLO fields. Both the get_graphic_double and get_control_double record support routines retrieve these fields. If these values are defined, they must be in the range: DRVL<=LOPR<=HOPR<=DRVH.
The PREC field determines the floating point precision with which to display VAL, OVAL and PVAL. It is used whenever the get_precision record support routine is called.
See Chapter 2, Fields Common to All Record Types, for more on the record name (NAME) and description (DESC) fields.
Field | Summary | Type | DCT | Initial | Access | Modify | Rec Proc Monitor | PP |
---|---|---|---|---|---|---|---|---|
EGU | Engineering Units | STRING [16] | Yes | null | Yes | Yes | No | No |
HOPR | High Operating Range | FLOAT | Yes | 0 | Yes | Yes | No | No |
LOPR | Low Operating Range | FLOAT | Yes | 0 | Yes | Yes | No | No |
PREC | Display Precision | SHORT | Yes | 0 | Yes | Yes | No | No |
NAME | Record Name | STRING [29] | Yes | 0 | Yes | No | No | No |
DESC | Description | STRING [29] | Yes | Null | Yes | Yes | No | No |
The limit alarms are configured by the user in the HIHI, LOLO, HIGH, and LOW fields, which must be floating-point values. For each of these fields, there is a corresponding severity field which can be either NO_ALARM, MINOR, or MAJOR.
See Alarm Specification, Chapter 1, 4, for a complete explanation of alarms and these fields. See Chapter 3.5, Invalid Alarm Output Action, for more information on the IVOA and IVOV fields. Alarm Fields, Chapter 2, 3, lists other fields related to a alarms that are common to all record types.
Field | Summary | Type | DCT | Initial | Access | Modify | Rec Proc Monitor | PP |
---|---|---|---|---|---|---|---|---|
HIHI | Hihi Alarm Limit | FLOAT | Yes | 0 | Yes | Yes | No | Yes |
HIGH | High Alarm Limit | FLOAT | Yes | 0 | Yes | Yes | No | Yes |
LOW | Low Alarm Limit | FLOAT | Yes | 0 | Yes | Yes | No | Yes |
LOLO | Lolo Alarm Limit | FLOAT | Yes | 0 | Yes | Yes | No | Yes |
HHSV | Hihi Alarm Severity | GBLCHOICE | Yes | 0 | Yes | Yes | No | Yes |
HSV | High Alarm Severity | GBLCHOICE | Yes | 0 | Yes | Yes | No | Yes |
LSV | Low Alarm Severity | GBLCHOICE | Yes | 0 | Yes | Yes | No | Yes |
LLSV | Lolo Alarm Severity | GBLCHOICE | Yes | 0 | Yes | Yes | No | Yes |
HYST | Alarm Deadband | DOUBLE | Yes | 0 | Yes | Yes | No | No |
IVOA | Invalid Alarm Output Action | GBLCHOICE | Yes | 0 | Yes | Yes | No | No |
IVOV | Invalid Alarm Output Value, in eng. units | DOUBLE | Yes | 0 | Yes | Yes | No | No |
Field | Summary | Type | DCT | Initial | Access | Modify | Rec Proc Monitor | PP |
---|---|---|---|---|---|---|---|---|
ADEL | Archive Deadband | DOUBLE | Yes | 0 | Yes | Yes | No | No |
MDEL | Monitor, i.e. value change, Deadband | DOUBLE | Yes | 0 | Yes | Yes | No | No |
The ORAW field is used to decide if monitors should be triggered for RVAL when monitors are triggered for VAL. The RBV field is the actual read back value obtained from the hardware itself or from the associated device driver. It is the responsibility of the device support routine to give this field a value.
ORBV is used to decide if monitors should be triggered for RBV at the same time monitors are triggered for changes in VAL.
The LALM, MLST, and ALST fields are used to implement the hysteresis factors for monitor callbacks.
The INIT field is used to initialize the LBRK field and for smoothing.
The PBRK field contains a pointer to the current breakpoint table (if any), and LBRK contains a pointer to the last breakpoint table used.
The OMOD field indicates whether OVAL differs from VAL. It will be different if VAL or OVAL have changed since the last time the record was processed, or if VAL has been adjusted by OROC during the current processing..
Field | Summary | Type | DCT | Initial | Access | Modify | Rec Proc Monitor | PP |
---|---|---|---|---|---|---|---|---|
ORAW | Old Raw Value | LONG | No | 0 | Yes | No | No | No |
RBV | Read Back Value | LONG | No | 0 | Yes | No | Yes | No |
ORBV | Old read back value | LONG | No | 0 | Yes | No | No | No |
LALM | Last Alarm Monitor Trigger Value | DOUBLE | No | 0 | Yes | No | No | No |
ALST | Last Archiver Monitor Trigger Value | DOUBLE | No | 0 | Yes | No | No | No |
MLST | Last Value Change Monitor Trigger Value | DOUBLE | No | 0 | Yes | No | No | No |
INIT | Initialize | SHORT | No | 0 | Yes | No | No | No |
PBRK | Address of Breakpoint Table | NOACCESS | No | 4 | No | No | No | |
LBRK | Last Breakpoint | SHORT | No | 0 | Yes | No | No | No |
PVAL | Previous Data Value | DOUBLE | No | 0 | Yes | No | No | No |
OMOD | OVAL modified? | LONG | No | Null | Yes | No | No | No |
The following fields are used to operate the analog output in the simulation mode. See Chapter 3, Fields Common to Many Record Types, for more information on these fields.
Field | Summary | Type | DCT | Initial | Access | Modify | Rec Proc Monitor | PP |
---|---|---|---|---|---|---|---|---|
SIOL | Simulation Value Location | INLINK | Yes | 0 | No | No | N/A | No |
SVAL | Simulation Value | DOUBLE | No | 0 | Yes | Yes | No | No |
SIML | Simulation Mode Location | INLINK | Yes | 0 | No | No | N/A | No |
SIMM | Simulation Mode | GBLCHOICE | No | 0 | Yes | Yes | No | No |
SIMS | Simulation Mode Alarm Severity | GBLCHOICE | Yes | 0 | Yes | Yes | No | No |
get_units
,
get_precision
, get_graphic_double
, and get_control_double
routines.This routine next checks to see that device support is available. If DOL is a constant, then VAL is initialized with its value and UDF is set to FALSE.
The routine next checks to see if the device support write routine is defined. If either device support or the device support write routine does not exist, an error message is issued and processing is terminated.
If device support includes init_record, it is called.
INIT is set TRUE[. This causes PBRK, LBRK, and smoothing to be re-initialized If linear conversion is requested, then VAL is computed from RVAL using the algorithm:
VAL = (RVAL+ROFF) / ESLO + EGULand UDF is set to FALSE.
For breakpoint conversion, a call is made to cvtEngToRawBpt and UDF is then set to FALSE. PVAL is set to VAL.
INIT is set TRUE. This causes PBRK, LBRK, and smoothing to be re-initialized.
upper_alarm_limit = HIHI
upper_warning_limit = HIGH
lower_warning_limit = LOW
lower_alarm_limit = LOLO
if DOL is DB_LINK and OMSL is CLOSED_LOOP get value from DOL if OIF is INCREMENTAL then set value = value + VAL else value = VAL
If Drive limits are defined force value to be within limits Set VAL equal to value Set UDF to FALSE. If OVAL is undefined set it equal to value If OROC is defined and not 0 make |value-OVAL| <=OROC Set OVAL equal to value Compute RVAL from OVAL. using linear or break point table conversion. For linear conversions the algorithm is: RVAL = (OVAL-EGUL)/ESLO -ROFF
Name | Summary | Description |
---|---|---|
PACT | Processing Active | See Chapter 2, Fields Common to All Record Types for an explanation of these fields. |
DPVT | Device Private | |
NSEV | New Alarm Severity | |
NSTA | New Alarm Status | |
OUT | Output Link | This field is used by the device support routines to locate its output. |
EGUF | Engineering Units Full | These fields are used to calculate ESLO. Note that these fields correspond to the high and low hardware limits. |
EGUL | Engineering Unit Low | |
ESLO | Slope | These fields are used for linear conversions from raw to engineering units. The device support routines must calculate these fields unless they obtain values already in engineering units. |
ROFF | Raw Offset | |
RVAL | Raw Value | This is the value to write to OUT. |
init()This routine is called once during IOC initialization.
init_record(precord)This routine is optional. If provided, it is called by the record support init_record routine. It returns a zero for success or a 2 for success, don't convert.
get_ioint_info(int cmd,struct dbCommon *precord,IOSCANPVT *ppvt)This routine is called by the ioEventScan system each time the record is added or deleted from an I/O event scan list. cmd has the value (0,1) if the record is being (added to, deleted from) an I/O event list. It must be provided for any device type that can use the ioEvent scanner.
write_ao(precord)This routine must output a new value. Asynchronous device support routines will return with PACT set to TRUE. If PACT is TRUE, the process routine will just return and not continue processing. When the asynchronous routine completes, it can call process which will again call write_ao. When finished, write_ao should set PACT to FALSE and return one the following values:
special_linconv(precord,after)This routine is called whenever either of the fields LINR, EGUF, EGUL or ROFF is modified.
If the OUT link type is PV_LINK, then dbCaAddInlink is called by init_record. init_record always returns a value of 2, which means that no conversion will ever be attempted.
write_ao calls recGblPutLinkValue to write the current value of VAL. See Soft Output, Chapter 3, 3.2, for details.
Generated with Harlequin WebMaker