This page maintained by moller@jlab.org
1. Moller DAQ
Updated: March 21 2003 This file: www.jlab.org/~moller/proglist.html
CRLFILES
Executable file: ~moller/daq/coda2/crlppc/moller_onl.o
runs on VME PPC CPU.
~moller/daq/coda2/crlppc/event_list.o
runs on VME PPC CPU.
Description : This files are used by CODA2.0 for load detectors VME
crate and readout it.
File 'event_list.o' is used only if trigger comes from interrupt
board. In polling mode it is not necessary.
Inp. parameters: molpulser - disable(0)/ enable(2) pulser or
enable(64) LED generator for testing
adcevents - number of ADC events per helicity window
adcevents=99 for 30ms window
Using files : ~moller/daq/coda2/usrstrutils.c - makes to transfer
parameters to 'crl' code.
Using env. : no
Source files : ~moller/daq/coda2/crlppc/moller_onl.crl
~moller/daq/coda2/crlppc/event_list.crl
Makefile : makelist ppc
mollerSettings
Executable file: ~moller/bin/SunOS/mollerSettings
for SUN platform.
~moller/bin/HP-UX/mollerSettings
for HP platform.
Description : This program is GUI for setting parameters of
moller detectors electronics: discriminator thresholds,
PLU logic's, time delay ...
The program uses TCP/IP protocol to communicated
with server ,which runs in detectors VME crate.
Inp. parameters:
if input parameter is present , program just load setting
from file to VME crate in background mode without
users interaction.
Using files : ~moller/daq/coda2/DETSETCODA2 - file with parameters for
moller detector electronics settings
~moller/daq/coda2/LEDSETCODA2 - file with parameters for
moller detector electronics settings using LED generator
$RCDATABASE/DetConfig -file for save detector electronics
settings every time when parameters are changed.
The script 'getruninfo' reads detectors settings from
this file.
~moller/vxworks/mollerSettings_server_ppc.o - server
running in detectors VME crate. This program loads and starts
from ~moller/vxworks/hallavme5_c2.boot file, when
crate is rebooting.
Using env. : RCDATABASE - pointer to directory for save 'DetConfig' file.
Source files : ~moller/daq/settings/client-3.0/*.cc
Makefile : ~moller/daq/settings/client-3.0/Makefile
mollerSettings_server_ppc.o
Executable file: ~moller/vxworks/mollerSettings_server_ppc.o
runs on detectors VME PPC CPU.
Description : This program is server to communicating and setting parameters
of detectors electronics: discriminator thresholds,
PLU logic's, time delay ...
The program uses TCP/IP protocol to communicated
with client program, which runs on one from HallA computers.
Inp. parameters: no
Using files : no
Using env. : no
Source files : ~moller/daq/settings/server/vme_server.c
~moller/daq/settings/Command.h
Makefile : ~moller/daq/settings/server/Makefile_vme2300
mmonitor
Executable file: ~moller/bin/SunOS/mmonitor
for SUN only.
Description : This program makes periodically plot of adc and tdc
histograms on display, when CODA2.0 is running
The program uses DD system to getting data from detector
and HPLOT package to book and plot histo.
Inp. parameters: mmonitor [-f filename -w nwait -z nevents ]
-f filename get data from CODA file 'filename'
-w nwait is the sleep time between screens update
-z nevents is to specify the number of events
for screen update (nevents=5000 in common)
-d is for debug output
Using files : no
Using env. : ANA_DIR - pointer to directory for save histo to files:
'adc.ps' and 'tdc.ps'.
Source files : ~moller/dev/MollAna/new/mmain.c mevents.f defens.h
Makefile : ~moller/dev/MollAna/new/mkmonitor
Scripts
getruninfo
Executable file: ~moller/daq/coda2/scripts/getruninfo
Description : to get information about current run
(date,runnumber,runtype,detectors settings ...)
and save it to file $CODAPATH/RunInfo/mollerrun.set
Inp. parameters: no
Using files : getrunnumber - tcl/tk script to get runnumber from database
getconfig - tcl/tk script to get runtype from database
getdetset - executable program to read current
detectors electronics settings from binary
file $RCDATABASE/DetConfig and print it to text
file $CODAPATH/RunInfo/mollerrun.set
adcread - script to get Hcoils current(Amps) and target
structure temperature.
moller.epics - file with data from epics variables
( beam current, magnets current, target position ...)
Using env. : CODAPATH - pointer to directory with files that are
used for CODA2.0 and DAQ runs.
Source files : ~moller/daq/coda2/scripts/getruninfo
Makefile : no
getendruninfo
Executable file: ~moller/daq/coda2/scripts/getendruninfo
Description : to get information about end of current run
(date,time,runnumber), and copy
file $CODAPATH/RunInfo/mollerrun.set
to file $CODAPATH/RunInfo/mollerrun_NN.set,
where NN is run number.
Inp. parameters: no
Using files : getrunnumber - tcl/tk script to get runnumber from database
Using env. : CODAPATH - pointer to directory with files that are
used for CODA2.0 and DAQ runs.
Source files : ~moller/daq/coda2/scripts/getendruninfo
Makefile : no
getepicsinfo
Executable file: ~moller/daq/coda2/scripts/getepicsinfo
Description : to get information about current run from epics variables
(beam current, magnets current, target position ...)
and save it to file $CODAPATH/RunInfo/moller.epics
Inp. parameters: no
Using files : ~moller/bin/SunOS/caget to get value from epics variables
~moller/bin/Linux/caget - to get value from epics variables
Using env. : CODAPATH - pointer to directory with files that are
used for CODA2.0 and DAQ runs.
EPICS_CA_ADDR_LIST - list of IP addresses of VME crates,
which runs EPICS control.
Source files : ~moller/daq/coda2/scripts/getepicsinfo
Makefile : no
adcread
Executable file: ~moller/daq/coda2/scripts/adcread
Description : to get data about Hcoils current(Amps) and
target temperature.
Inp. parameters: no
Using files : ~moller/bin/$OSNAME/mcomm - uses TCP/IP
to control ADC and DAC (in target VME crate)
and get data from ADC.
$CODAPATH/Settings/config_adcread.adc - file with
parameters for ADC settings.
Format:
NCHAN 2
NPOINT 100
TTIMER 9
TSAMPLE 10
MODE 1
SCANLIST 1
7 -1
8 4
where: NCHAN 2 is number of using adc channels
NPOINT 100 is number of points for measurement
TTIMER 9 is sample rates from
expression TTIMER=10000/samplerate(Hz) - 1
TSAMPLE 10 - time(ms) between channels scan
MODE 1 - mode of ADC trigger:
0 - soft arm and trigger
1 - soft arm and internal trigger(TTIMER)
2 - ext arm and trigger
SCANLIST 1 - define scanlist of channels ADC
7 -1 -
8 4 -
where inputrange is:
-1 - auto
0 - +/-0.0625V
1 - +/-0.25V
2 - +/-1V
3 - +/-4V
4 - +/-16V
~moller/daq/coda2/scripts/avr - program to average
set of data from adc (to get more precaisly temperature
from termoprobe)
~moller/daq/coda2/scripts/tempconv - program to convert
value from termoprobes in V, to value in K deg.
Using env. : CODAPATH - pointer to directory with files that are
used for CODA2.0 and DAQ runs.
Source files : ~moller/daq/coda2/scripts/adcread
Makefile : no
dacdownload
Executable file: ~moller/daq/coda2/scripts/dacdownload
Description : init DAC, load linear waveform to DACs RAM.
Calls from CODA2.0 runcontrol when 'Download'
button is pressed in 'beampol' configuration.
Inp. parameters: no
Using files : ~moller/daq/coda2/scripts/mcomm - uses TCP/IP
to control ADC and DAC (in target VME crate)
Using env. : CODAPATH - pointer to directory with files that are
used for CODA2.0 and DAQ runs.
Source files : ~moller/daq/coda2/scripts/dacdownload
Makefile : no
dacsetup
Executable file: ~moller/daq/coda2/scripts/dacsetup
Description : setup output value of DAC (and Hcoils current)
to value 9.0 Amps or -9.0 Amps. Sign is changed
every next run of CODA.
Calls from CODA2.0 runcontrol when 'Prestart'
button is pressed in 'beampol' configuration.
Inp. parameters: no
Using files : ~moller/daq/coda2/scripts/mcomm - uses TCP/IP
to control ADC and DAC (in target VME crate)
~moller/daq/coda2/scripts/.sign - to store sign(1/-1) of
Hcoils current between runs.
Using env. : CODAPATH - pointer to directory with files that are
used for CODA2.0 and DAQ runs.
Source files : ~moller/daq/coda2/scripts/dacsetup
Makefile : no
dacend
Executable file: ~moller/daq/coda2/scripts/dacend
Description : setup output value of DAC (and Hcoils current)
to value 0.0 Amps and disables output of DAC
Calls from CODA2.0 runcontrol when 'End Run'
button is pressed in 'beampol' configuration.
Inp. parameters: no
Using files : ~moller/daq/coda2/scripts/mcomm - uses TCP/IP
to control ADC and DAC (in target VME crate)
~moller/daq/coda2/scripts/.sign - to store sign(1/-1) of
Hcoils current between runs.
Using env. : CODAPATH - pointer to directory with files that are
used for CODA2.0 and DAQ runs.
Source files : ~moller/daq/coda2/scripts/dacend
Makefile : no
mollinfo
Executable file: ~moller/daq/coda2/scripts/mollinfo
Description : Tcl/tk script shows value of epics variables:
magnets curren, beam current, target position ...
Inp. parameters: no
Using files : ~moller/bin/$OSNAME/caget - to get value of epics variables
Using env. : EPICS_CA_ADDR_LIST - list of IP addresses of VME crates,
on which runs EPICS control.
Source files : ~moller/daq/coda2/scripts/mollinfo
Makefile : no
2. Target magnetization measurement
mcomm
Executable file: ~moller/bin/$OSNAME/mcomm
Description : to control ADC and DAC by sending commands
(using TCP/IP) to server, running in targets VME crate.
Inp. parameters: mcomm -d {module} -c {command} [parameter]
module:
adc - name of module
dac - name of module
command: parameter:
init - initilization of module
setup FILENAME - load module settings from FILENAME
start - triggering of module
stop - stop of running module
reset - reset of module to init state
only ADC commands:
getdata - get and print data from ADC
only DAC commands:
load WAVE - load waveform to dac: WAVE=ramp
setout VAL - setup output of dac to value VAL(float)
outdis CHN - disable output of DAC channel(CHN=0 or 1)
outen CHN - enable output of DAC channel(CHN=0 or 1)
Example1: to init adc:
mcomm -d adc -c init
Example2: to load settings parameter of dac from file 'config.dac':
mcomm -d dac -c setup config.dacUsing files : ~moller/dev/vx/vme_server/vme_server.o - server
runs in target VME crate. This program loads and
starts from ~moller/halladaq14.boot file, while
crate is rebooting.
Using env. : VME_HOST - name(address) of VME crate to communicating
VME_HOST=halladaq14 for Hall A
VME_HOST=halladaq10 for stend in EEL bld.
Source files : ~moller/dev/vx/client/Comm.c - main program
~moller/dev/vx/client/defs.h Comman.h
Makefile : ~moller/dev/vx/client/mkcom
vme_server.o
Executable file: ~moller/dev/vx/vme_server.o
runs on targets VME CPU.
Description : This program is server to control ADC and DAC in target VME crate.
The program receives command from client program,
which runs on one from HallA computers.
Inp. parameters: no
Using files : ~moller/dev/adcdac/adcHP.o - routines to control ADC type HPE1313A
~moller/dev/adcdac/dacVMI.o - routines to conrol DAC type VMIVME1415
Using env. : no
Source files : ~moller/dev/vx/vme_server/vme_server.c
~moller/dev/vx/vme_server/Command.h
Makefile : ~moller/dev/vx/vme_server/Makefile
tmag.tcl
Executable file: 'wish4.0 -f ~moller/stand/tmag.tcl'
or
'dpwish -f ~moller/stand/tmag.tcl' only for SUN platform
Description : This program is user interface to make target magnetization
measurement and store data to file for analysis.
Inp. parameters: no
Using files : ~moller/stand/setup_adc.tcl - tcl/tk routines to setup
ADC parameters
~moller/stand/setup_dac.tcl - tcl/tk routines to setup
DAC parameters
~moller/stand/config1.adc config2.adc config3.adc - files with
stored ADC parameters to configure of ADC.
Format: see upper
~moller/stand/config1.dac config2.dac config3.dac - files with
stored DAC parameters to configure of DAC:
Format:
CHAN 0
WAVE SINE
AMPL 8.0
SHIFT 0.0
FREQ 4.0
FSAMPLE 100000.0
NUMPERIODS 30
where:
CHAN 0 - number of output DAC channel for using (0 or 1)
WAVE - type of waveform to generate
SINE - sine wave
TRIANGLE - ramp linear wave
SQUARE - square wave (don't tested)
AMPL 8.0 - amplitude of wave in Volts
SHIFT 0.0 - DC shift of wave in Volts
FREQ 4.0 - wave frequency in Hz
FSAMPLE 100000.0 - sample rates(Hz) of DAC to produce wave
NUMPERIODS 30 - number of wave periods
(511 - continuos wave generation)~moller/bin/SunOS/mcomm or
~moller/bin/HP-UX/mcomm - to control ADC and DAC
in targets VME crate.
Using env. : CONFIG_DIR - pointer to directory with configuration files
for ADC and DAC setings.
Source files : ~moller/stand/tmag.tcl
Makefile : no
magnet.kumac
Executable file: ~moller/stand/magnet.kumac
PAW macro file
Description : This macros is used to analysis data from targets pickup coils
and to extract target polarization.
Inp. parameters: magnet targ=targ file1=file1 file2=file2 sample=sampl chan=chan fitt=fitt
file1 = name of file with data for air coefficient calculation
file2 = name of file with data for calculation of foil polarization
sample = number point of ADC on period of sinewave
sampl=ADCrate(10kHz)/frequencyofsinewave (default 2500)
fitt = 1/0 -use or not fitting vectors for coefficients calculation
(default 1)
chan = number of channels(2-3) in data file (default 3)
(last channel should be allways Hcoils current channel)
datafile format (all value are float):
chan1value1 chan2value1 ****
chan1value2 chan2value2 ****
**** **** ****
targ = what target are used (1=top, 2=bottom)
Using files : ~moller/stand/tagetdata.kumac - setup values for targets parameters:
size, mass, density ...
~moller/stand/coefcalc.kumac - macro to calculate coefficients for
air flux subtraction
~moller/stand/fitcoils.kumac - macro to fitting pickups signal by sine
and extract sine parameters
Using env. : no
Source files : ~moller/stand/magnet.kumac
~moller/stand/tagetdata.kumac
~moller/stand/coefcalc.kumac
~moller/stand/fitcoils.kumac
Makefile : no