MRD-100 Machine Status Link
Author: APS BCDA
Table of contents
The MRD-100 is a VMEbus Machine Status Link (MSL) module that provides real-time access to accelerator status data from the APS storage ring. The module is located in the A32/D32 VME address space and provides data including beam current, lifetime, BPM positions, insertion device status, front-end shutter states, and other beamline-relevant signals.
Configuration
An iocsh script is provided that handles configuration and database loading:
iocshLoad("$(VME)/iocsh/MSL_MRD100.iocsh", "PREFIX=xxx:, INSTANCE=msl:, VME=$(VME), ADDRESS=0xA0000200, INT_VEC=0xA0")
| Macro | Required | Default | Description |
|---|---|---|---|
PREFIX | Yes | – | IOC prefix |
INSTANCE | Yes | – | Instance prefix |
ADDRESS | Yes | – | A32 base address |
INT_VEC | Yes | – | Interrupt vector |
VME | Yes | – | Location of vme module |
INT_LVL | No | 5 | Interrupt level |
CARD | No | 0 | Card number |
ID1 | No | $(INSTANCE) | ID1 prefix |
ID2 | No | $(INSTANCE)us | ID2 prefix |
The script calls devAvmeMRDConfig(base, vector, level) and loads msl_mrd100.db. For canted undulator beamlines, use MRD100_CantedID.db instead.
Only one instance of the MRD-100 is supported.
When configuring manually:
devAvmeMRDConfig(0xA0000200, 0xA0, 5)
dbLoadRecords("$(VME)/vmeApp/Db/msl_mrd100.db", "C=0,S=$(INSTANCE),ID1=$(INSTANCE),ID2=$(INSTANCE)us")
Supported Record Types
All use DTYP "MRD-100" with VME_IO link type.
Link Format
field(INP, "#C<card> S<register> @<parm>")
field(OUT, "#C<card> S<register> @<parm>")
Where card is always 0 and register is the register number.
PARM Field Formats
| Record Type | PARM Format | Description |
|---|---|---|
| ai | s,w,t | s=start bit, w=width, t=type (0=unipolar, 1=bipolar) |
| bi | s | s=bit number |
| bo | s | s=bit number |
| longin | s,w | s=start bit, w=width |
| mbbi | s | s=start bit |
Debug Variable
var devAvmeMRDDebug 0
| Level | Output |
|---|---|
| 0 | No messages |
| >= 5 | Write command messages |
| >= 10 | Read command messages |