Skip to content
Snippets Groups Projects
Commit 57e0c05b authored by Eric Pooser's avatar Eric Pooser
Browse files

Add HMS trigger detector map

Add HMS trigger information to README

Modify crate map generator to include a more robust user interface
parent abc1310a
No related branches found
No related tags found
No related merge requests found
!HMS:
! HCAL_ID= 5 ADC, TDC
ROC=1
detector=5
! Plane = 1 >> ADC Only
! Plane = 2 >> TDC Only
! Plane = 3 >> Both ADC & TDC
!F250 module
SLOT=17
! chan plane bar sig
8, 3, 1, 0! hASUM
9, 3, 2, 0! hBSUM
10, 3, 3, 0! hCSUM
11, 3, 4, 0! hDSUM
12, 4, 1, 0! hPSHWR
13, 3, 5, 0! hSHWR
14, 3, 6, 0! hAERSUM
15, 3, 7, 0! hCERSUM
!CAEN1190 module
SLOT=2
! A0
! chan TDC bar sig
0, 2, 1 0! h1X
1, 2, 2 0! h1Y
2, 2, 3 0! h2X
3, 2, 4 0! h2Y
4, 2, 5 0! h1T
5, 2, 6 0! h2T
6, 2, 7 0! hT
7, 3, 1 0! hASUM
8, 3, 2 0! hBSUM
9, 3, 3 0! hCSUM
10, 3, 4 0! hDSUM
11, 4, 1 0! hPSHWRLO
12, 4, 1 0! hPSHWRHI
13, 3, 5 0! hSHWR
14, 3, 6 0! hAERSUM
15, 3, 7 0! hCERSUM
!CAEN1190 module
SLOT=20
! D1
! chan TDC bar sig
127, 2, 7 1! hT
\ No newline at end of file
...@@ -8,11 +8,19 @@ ...@@ -8,11 +8,19 @@
!The following lists the various HMS crates read out in Hall C !The following lists the various HMS crates read out in Hall C
Crate 1 >> Hodoscope (ADC,TDC), Calorimeter (ADC), Aerogel (ADC), Cherenkov (ADC) >> Trigger (ADC,TDC) !Crate 1 >> Hodoscope (ADC,TDC), Calorimeter (ADC), Aerogel (ADC), Cherenkov (ADC) >> Trigger (ADC,TDC)
Crate 3 >> Drift Chambers (TDC) !Crate 3 >> Drift Chambers (TDC)
Crate 5 >> Hardware Scalers !Crate 5 >> Hardware Scalers
!The shell script "make_cratemap.sh" exists so that the user can create a singular crate map
!db_cratemap.dat which contains the necessary information from various crates in both the
!HMS & SHMS spectrometer arms to run the analyzer. The script prompts the user to enter
!the crate number(s), separated by spaces, in which they would like a crate map to be
!generated for. The file "db_cratemap.dat" id created in the current working directory. It
!is useful to note that one could do this by hand simply by cat-ing the desired crate maps
! in both the HMS & SHMS MAPS directories.
!:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:= !:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
...@@ -47,7 +55,7 @@ Detector: HMS Aerogel >> Decetor ID: HAERO_ID= 7 >> Detector Map: haero.map ...@@ -47,7 +55,7 @@ Detector: HMS Aerogel >> Decetor ID: HAERO_ID= 7 >> Detector Map: haero.map
FADC:hAero[1-8]+ >> Slot 17 >> Chan 0 - 7 FADC:hAero[1-8]+ >> Slot 17 >> Chan 0 - 7
FADC:hAero[1-8]- >> Slot 16 >> Chan 8 - 15 FADC:hAero[1-8]- >> Slot 16 >> Chan 8 - 15
!NOTE: As of 11/16/2016 all 16 chanels in the aerogel are noisy and not fir for production !NOTE: As of 11/16/2016 all 16 chanels in the aerogel are noisy and not fit for production
!running. This detector will not be used in the Srping 2017 commissioning runs !running. This detector will not be used in the Srping 2017 commissioning runs
!:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:= !:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
...@@ -72,35 +80,39 @@ FADC:hD[1-13]+ >> Slot 7 >> Chan 1 - 13 ...@@ -72,35 +80,39 @@ FADC:hD[1-13]+ >> Slot 7 >> Chan 1 - 13
Detector: Trigger >> Dectector ID: HTRIG_ID= 8 >> Detector Map: htrig.map Detector: Trigger >> Dectector ID: HTRIG_ID= 8 >> Detector Map: htrig.map
! Calorimeter Trigger FADC Channels ! Calorimeter Trigger FADC Channels
FADC:hASUM >> Slot 17 >> Chan 8 FADC:hASUM >> Slot 17 >> Chan 8 ! Sum of A+ & A-
FADC:hBSUM >> Slot 17 >> Chan 9 FADC:hBSUM >> Slot 17 >> Chan 9 ! Sum of B+ & B-
FADC:hCSUM >> Slot 17 >> Chan 10 FADC:hCSUM >> Slot 17 >> Chan 10 ! Sum of C+ & C-
FADC:hDSUM >> Slot 17 >> Chan 11 FADC:hDSUM >> Slot 17 >> Chan 11 ! Sum of D+ & D-
FADC:hPSHWR >> Slot 17 >> Chan 12 FADC:hPSHWR >> Slot 17 >> Chan 12 ! Sum of A & B
FADC:hSHWR >> Slot 17 >> Chan 13 FADC:hSHWR >> Slot 17 >> Chan 13 ! Sum of A, B, C, & D
! Calorimeter Trigger TDC Channels
TDC:hASUM >> Slot 2 >> Sub-Slot >> Chan ! Sum of A+ & A-
TDC:hBSUM >> Slot 2 >> Sub-Slot >> Chan ! Sum of B+ & B-
TDC:hCSUM >> Slot 2 >> Sub-Slot >> Chan ! Sum of C+ & C-
TDC:hDSUM >> Slot 2 >> Sub-Slot >> Chan ! Sum of D+ & D-
TDC:hPSHWR >> Slot 2 >> Sub-Slot >> Chan ! Sum of A & B
TDC:hSHWR >> Slot 2 >> Sub-Slot >> Chan ! Sum of A, B, C, & D
! Hodoscope Trigger TDC Channels ! Hodoscope Trigger TDC Channels
TDC:h1X >> Slot 2 >> Sub-Slot >> Chan TDC:h1X >> Slot 2 >> Sub-Slot A0 >> Chan 0 ! (OR of +) AND (OR of -)
TDC:h1Y >> Slot 2 >> Sub-Slot >> Chan TDC:h1Y >> Slot 2 >> Sub-Slot A0 >> Chan 1 ! (OR of +) AND (OR of -)
TDC:h2X >> Slot 2 >> Sub-Slot >> Chan TDC:h2X >> Slot 2 >> Sub-Slot A0 >> Chan 2 ! (OR of +) AND (OR of -)
TDC:h2Y >> Slot 2 >> Sub-Slot >> Chan TDC:h2Y >> Slot 2 >> Sub-Slot A0 >> Chan 3 ! (OR of +) AND (OR of -)
TDC:h1T >> Slot 2 >> Sub-Slot >> Chan TDC:h1T >> Slot 2 >> Sub-Slot A0 >> Chan 4 ! h1x AND h1Y
TDC:h2T >> Slot 2 >> Sub-Slot >> Chan TDC:h2T >> Slot 2 >> Sub-Slot A0 >> Chan 5 ! h2x AND h2y
TDC:hT >> Slot 2 >> Sub-Slot >> Chan TDC:hT >> Slot 2 >> Sub-Slot A0 >> Chan 6 ! h1T AND h2T
TDC:hT >> Slot 20 >> Sub-Slot D1 >> Chan 127 ! h1T AND h2T
! Cherenkov Trigger Channel ! Calorimeter Trigger TDC Channels
TDC:hCerT >> Slot 2 >> Sub-Slot >> Chan ! Sum of channels 1 & 2 TDC:hASUM >> Slot 2 >> Sub-Slot A0 >> Chan 7 ! Sum of A+ & A-
TDC:hBSUM >> Slot 2 >> Sub-Slot A0 >> Chan 8 ! Sum of B+ & B-
TDC:hCSUM >> Slot 2 >> Sub-Slot A0 >> Chan 9 ! Sum of C+ & C-
TDC:hDSUM >> Slot 2 >> Sub-Slot A0 >> Chan 10 ! Sum of D+ & D-
TDC:hPSHWRLO >> Slot 2 >> Sub-Slot A0 >> Chan 11 ! Sum of A & B, low threshold
TDC:hPSHWRHI >> Slot 2 >> Sub-Slot A0 >> Chan 12 ! Sum of A & B, high threshold
TDC:hSHWR >> Slot 2 >> Sub-Slot A0 >> Chan 13 ! Sum of A, B, C, & D
! Aerogel Trigger Channel ! Aerogel Trigger Channel
TDC:hAeroT >> Slot 2 >> Sub-Slot >> Chan ! Sum of 8+ chan 8- FADC:hAERSUM >> Slot 17 >> Chan 14 ! Sum of channels [1-8]+ & [1-8]-
TDC:hAERSUM >> Slot 2 >> Sub-Slot A0 >> Chan 14 ! Sum of channels [1-8]+ & [1-8]-
! Cherenkov Trigger Channel
FADC:hCERSUM >> Slot 17 >> Chan 15 ! Sum of channels [1-2]
TDC:hCERSUM >> Slot 2 >> Sub-Slot A0 >> Chan 15 ! Sum of channels [1-2]
!:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:= !:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=
......
...@@ -2,21 +2,44 @@ ...@@ -2,21 +2,44 @@
# Shell script to merge multiple crate maps into one # Shell script to merge multiple crate maps into one
# Author: Eric Pooser, pooser@jlab.org, 11/17/16 # Author: Eric Pooser, pooser@jlab.org, 11/17/16
echo function proceed {
read -p "Enter the crate(s), separated by spaces, you would like form a single crate map for > " list rm -f db_cratemap.dat
echo ;read -p "Enter the crate(s), separated by spaces, you would like to form a single crate map for > " list
arr=($list)
for crate in "${arr[@]}"; do
if ((${crate} < 1)) || ((${crate} > 7)); then
echo; echo "You must enter an integer value in the range [1, 7]"; echo
exit
fi
done
for crate in "${arr[@]}"; do
if ((crate%2 == 1)) && ((crate != 7)); then
(cat ${PWD}/HMS/db_crate${crate}map.dat; echo; echo) >> db_cratemap.dat
echo; echo "HMS Crate ${crate} has been added to db_cratemap.dat"
elif ((crate%2 == 0)) || ((crate == 7)); then
(cat ${PWD}/SHMS/db_crate${crate}map.dat; echo; echo) >> db_cratemap.dat
echo; echo "SHMS Crate ${crate} has been added to db_cratemap.dat"
if ((crate == 7)); then echo; fi
fi
done
}
arr=($list) function ask_proceed {
read -p "Would you like to proceed? (yes or no) > " response
for crate in "${arr[@]}"; do if [[ $response = "no" ]]; then
if ((${crate} < 1)) || ((${crate} > 7)); then echo; "Please rename/move db_cratemap.dat in the current working directory before proceeding"; echo
echo "You must enter an integer value in the range [1, 7]"
exit exit
elif ((crate%2 == 1)) && ((crate != 7)); then elif [[ $response = "yes" ]]; then
(cat ${PWD}/HMS/db_crate${crate}map.dat; echo; echo) >> db_cratemap.dat proceed
echo "HMS Crate ${crate} has been added to db_cratemap.dat" else
elif ((crate%2 == 0)) || ((crate == 7)); then echo; echo "Please respond by specifically typing yes or no"; echo; exit
(cat ${PWD}/SHMS/db_crate${crate}map.dat; echo; echo) >> db_cratemap.dat
echo "SHMS Crate ${crate} has been added to db_cratemap.dat"
fi fi
done }
file=( $(find db_cratemap.dat -type f 2> /dev/null) )
if [[ ${file[0]} = "db_cratemap.dat" ]]; then
echo; echo "CAUTION: The file db_cratemap.dat will be created/overwritten!!!"; echo
ask_proceed
else
proceed
fi
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment