'PARAM.INC

'****************************************************************************
'This file contains all the parameters of the magnet test.  It also contains
'parameters defined in the program such as filenames.  Such parameters
'are put in common blocks.
'
'Zachary Wolf
'4/16/94, 9/10/94
'****************************************************************************

'GPIB PARAMETERS

'Make GPIB input and output files common to all procedures
COMMON SHARED /gpib/ gpibinP%, gpiboutP%

'Define the GPIB addresses
CONST hp3457addrP% = 22      'HP3457A DVM GPIB address
CONST bit488addrP% = 1       'the Kepco BIT488 GPIB address

'MEASUREMENT PARAMETERS

'Resistance and temperature measurement parameters
CONST vmaghpchanP% = 4       'HP3457 magnet voltage channel
CONST t1hpchanP% = 5         'HP3457 T1 temperature channel
CONST t1P$ = "Magnet Coil"
CONST t2hpchanP% = 6         'HP3457 T2 temperature channel
CONST t2P$ = "Magnet Iron"
CONST t3hpchanP% = 7         'HP3457 T3 temperature channel
CONST t3P$ = "Ambient"
CONST tbtwnmeassecP% = 60    '# seconds between RT measurements

'Magnet current set and measurement parameters
CONST imaghpchanP% = 0       'HP3457 channel for the transductor voltage
CONST vtransperimagP! = .4   'transductor voltage per magnet amp (10 V = 125 A transductor, 5 turns)
CONST ibopramprateP! = 3!    'current ramp rate (A/s)
CONST bit488vminP! = -20!    'the minimum Kepco bop supply voltage
CONST bit488vmaxP! = 20!     'the maximum Kepco bop supply voltage
CONST bit488iminP! = -20!    'the minimum Kepco bop supply current
CONST bit488imaxP! = 20!     'the maximum Kepco bop supply current
CONST bit488vlimP! = 20!     'the voltage magnitude limit in constant current mode
CONST bit488ilimP! = 20!     'the current magnitude limit in constant voltage mode
CONST tstableP% = 2!         'settling time after a ramp

'Coil voltage measurement parameters
CONST coil1hpchanP% = 1      'HP3457 channel # for coil 1 voltage
CONST coil12hpchanP% = 2     'HP3457 channel # for coils 1 and 2 in series
CONST freqhpchanP% = 3       'HP3457 channel # for the coil frequency
CONST nsampleP% = 64         'the number of voltage samples per revolution
CONST nrotaveP% = 10         'the number of coil rotations for V average
CONST nmeasaveP% = 4         'the number of measurements for B average
CONST nhardisplayP% = 16     'the number of harmonics to print out < nsampleP%/2

'Coil parameters
CONST nturnscoil1P% = 30     'number of turns on measurement coil 1
CONST nturnscoil12P% = 30    'number of turns on measurement coil 1 and 2
CONST rcoil1P! = .0175       'radius of coil 1 in m
'CONST rcoil12P! = .0268618   'effective radius of coils 1 and 2 in series in m

'COMMON BLOCKS

'Coil
COMMON SHARED /coil/ coilhpchanP%, rcoilP!, nturnscoilP%

'Put the test parameters in a common block
COMMON SHARED /testparam/ magnameP$, projectP$, teststandP$, coilnameP$, operatorP$, runP$, commentP$

'Make file names common to all procedures
COMMON SHARED /filenames/ logfileP$, rawfileP$, rtdatP$, dldatP$, dlpltP$, hardatP$, harpltP$

'Put the desired standardization and measurement currents in a common block
COMMON SHARED /currents/ imagstandP!(), imagtestP!(), imagharP!()

'Fill test parameters
projectP$ = "PEP II Injection Line"
teststandP$ = "Rotating Coil Stand 2"
coilnameP$ = "DC100"

'CURRENTS

'Define the standardization cycle
CONST nimagstandP% = 7       'the number of standardization currents
DIM imagstandP!(1 TO nimagstandP%)   'the current array
imagstandP!(1) = 6!          'standardization currents
imagstandP!(2) = -6!
imagstandP!(3) = 6!
imagstandP!(4) = -6!
imagstandP!(5) = 6!
imagstandP!(6) = -6!
imagstandP!(7) = 0!

'Define the test currents
CONST nimagtestP% = 25       'number of measurement currents
DIM imagtestP!(1 TO nimagtestP%)    'the current array
imagtestP!(1) = 0!           'GL vs I currents
imagtestP!(2) = 1!
imagtestP!(3) = 2!
imagtestP!(4) = 3!
imagtestP!(5) = 4!
imagtestP!(6) = 5!
imagtestP!(7) = 6!
imagtestP!(8) = 5!
imagtestP!(9) = 4!
imagtestP!(10) = 3!
imagtestP!(11) = 2!
imagtestP!(12) = 1!
imagtestP!(13) = 0!
imagtestP!(14) = -1!
imagtestP!(15) = -2!
imagtestP!(16) = -3!
imagtestP!(17) = -4!
imagtestP!(18) = -5!
imagtestP!(19) = -6!
imagtestP!(20) = -5!
imagtestP!(21) = -4!
imagtestP!(22) = -3!
imagtestP!(23) = -2!
imagtestP!(24) = -1!
imagtestP!(25) = 0!

'Define the test currents for harmonics printouts
'Note that the currents listed must be test currents to get a printout
CONST nimagharP% = 3         'number of currents for harmonics printout
DIM imagharP!(1 TO nimagharP%)    'the current array
imagharP!(1) = 2!            'harmonics printout currents
imagharP!(2) = 4!
imagharP!(3) = 6!

