How-To Modify the Magnet Database

LCLS Magnet PV Attributes
LCLS Magnet Device Names

SLC Database
The SLC Database is located on VMS under CMS control.

  • Log onto your VMS account
  • Gain access to REF_DBSFILES
  • Use the tool EDITDBS to edit your database
  • If you are changing a seconday that is supertype 1 then you will need to make this change in the corresponding EPICS database. Table 1.0 lists the magent primary secondaries that require changes to both SLC and EPICS databases. Please note that secondaries hightlighted in purple are not used in the LCLS Magnet Controls of new devices but are used in the Magnet controls of existing SLC devices.

Supertype data in the database is organized into large blocks called superblocks or supertypes. Five different supertypes are currently defined:

Supertype

Description

Access

0

Pointer Block

Write Protected

1

Stable Parameters Block

Write Protected

2

To Micro-cluster

Alpha Write only

3

From Micro-cluster

Alpha Read only

4

Host only parameters

No micro access

Supertypes 0 through 3 are sent to the micro-cluster at IPL. Subsequently only supertype 2 is transmitted to the micro-cluster and only supertype 3 is received from it. (Arbitrary subsets of these blocks may be transmitted as well as the full blocks). The Pointer block was designed as a separate structure to allow it to be write protected and to decrease the overhead associated with moving data. The Stable parameters are usually those that are in the database data files and do not normally change during the operation of the machine. If they are changed, it will be necessary to re-IPL the micros. The block are control parameters for the micro that are loaded by the dbput routines and automatically sent to the relevant micros. The From block is data sent by the micros and is loaded into the database by the DBEX process. Supertype 4 is data associated with a device on a micro but which the micro does not need. Thus it is kept as a separate block to reduce wasted storage in the micro.

Every SECN must belong to a supertype between 1 and 4, and this is specified in the PRIMARY file as the number supn.

EPICS Database
The EPICS Database is located on the SLAC Unix-Wide network. The database files are kept under under CVS control.

  • Verify that you have access to the ACL g-lcls. To check this log onto you Unix account and type the following command on the shell: pts members g-lcls

Cavots
If you are changing a seconday in the SLC database that is supertype 1, you will need to make this change in the corresponding EPICS database as well.

Table 1.0

SLC Database Magnet Secondaries

Secondary

Supertype

Data Type

Description

:PSNM: 1

4

2A4;

Power supply serial number

:BCON: 12

4

1R4;

B from configuration, not used by micro

:Z : 23

4

1R4;

Z of magnet center (Meters)

:BMAX: 26

4

1R4;

Maximum magnetic strength (Kilogauss)

:LEFF: 25

4

1R4;

Effective length of magnet (Meters)

:LABL: 36

4

1S4;

MAD Deck name

:OFFS: 37

4

2R4;

Offsets X and Y in MM for center of magnet

:KMOD: 90

4

1R4;

Normalized field strength)

:FRAC: 91

4

1R4;

fractional energy gain from model

:RMS : 92

4

1R4;

RMS value calculated by History Buffer

:TRMS: 94

4

1R4;

ratio of RMS tols to TOLS

:IVBU: 2

1

VR4;

Current = Function(B field) going up

:IVBD: 3

1

VR4;

Current = Function(B field) going down Polynomial fits to magnetic measurement data of current as a function of magnetic field strength

:IVA : 4

1

VR4;

Current = Function(ADC volts) Polynomial to convert ADC reading to current

:IVA2: 95

1

2R4;

Current = Function(ADC volts) for 2nd analog input

:DVI : 5

1

VR4;

DAC counts = Function(Current) trial polynomial (where DVI is the product of the DAC an Power supply transfer functions) DAC is 2's complement binary (3276 counts/volt) 1 DAC volt/ampere would have a DVI = 32760.,3276.

:TOLS: 6

1

4R4;

Tolerances on BDES. Pair 1 is for Trim, Pair 2 for Check 1st of each pair is an absolute tolerance (for small Abs(B)), 2nd is a FRACTIONAL error. A magnet is OK if either tolerance is satisfactory.

:IMMS: 7

1

3R4;

IMIN,IMAX and final Set point for STDZ or CAL

:IMMO: 24

1

2R4;

MIN,IMAX for operating conditions

:NSCY: 8

1

2I2;

1st is number of Standardization cycles (up/down =1) 2nd is interval before going down (MSEC)

:ADCP: 9

1

1Z2

Not used

:DACL: 10

1

1Z4;

Not used for channel 1H, slave 1H, master 600H.

:ATOL: 20

1

2R4;

Loose tolerance on desired current-ADC meas current used for calibration and standardization and for diagnostic knobs 1st is absolute tolerance, 2nd is fractional

:PSCP: 32

1

1I2;

Unit number of Large power supply (Ignore if magnet is on private supply)

:SETL:123

1

1I2;

Settling time for power supply to stabilise. (in msecs)

:RAMP: 33

1

2I4;

Ramping rate: max step size in Dac cnts, wait time (msec)

:HDSC: 49

1

1Z2;

Hardware descriptor

:BDES: 13

2

1R4;

B asked by magnet job

:HSTA: 28

2

1Z2;

Hardware status (see Bit definitions)

:VSTA: 66

4

1Z4;

VAX STAtus word

:DVIC: 18

3

VR4;

Calibrated DAC=F(I)

:DVIG: 21

3

1R4;

Calibrated DAC=F(I) goodness from fitting

:STAT: 14

3

1Z2;

Status (see Bit definitions)

:STA2:133

3

1Z4;

second status word (see Bit definitions)

:IDES: 19

3

1R4;

I calculated from BDES

:IPRV: 17

3

1R4;

Last recorded I in tolerance

:BACT: 15

3

1R4;

B at last check

:IACT: 16

3

1R4;

I at last check

:RIPL: 38

3

1R4;

Ripple read back from SAM

:IMAX:124

3

1R4;

Max (or min) recorded I for Stdz magnets

:DACV:125

3

1R4;

Last DAC value

:ITRY: 27

3

1I2;

Number of trys required to Trim

:TTIM: 29

3

2T4;

Last time successfully Trimmed

:CTIM: 30

3

2T4;

Last time successfully Calibrated

:KTIM: 31

3

2T4;

Last time successfully Standardized

:ZTIM:127

3

2T4;

Last time Standardization was lost

:EMOD: 88

4

1R4;

Beam energy (GeV) at magnet center

:ECON: 89

4

1R4;

Beam energy (GeV) at magnet center from configuration

:IMON:126

3

1R4;

PSC2 second analog signal

:BMON:135

3

1R4;

redundant transductor readback in field

:TOLF:132

1

1R4;

redundant transductor tolerance factor

:ADCR:134

1

1Z2;

pointer to ADC location in buffer of redundant readback