7 # ------------------------------------------------------------------------------------------ 
    9 #                Script to run JTriggerEfficiency in run-by-run mode. 
   11 # ------------------------------------------------------------------------------------------ 
   13 if [ -z $JPP_DIR ]; 
then 
   14     echo "Variable JPP_DIR undefined." 
   18 source $JPP_DIR/setenv.sh $JPP_DIR
 
   26 set_variable:  SAMPLER               TRIGGEREFFICIENCY_SAMPLER                  
"100 1000" 
   30     usage "$script <detector file> <detector file> (input file)+ <output file> <DAQ file> <PMT parameters file>"\
 
   31           "\nAuxiliary script to trigger Monte Carlo events." 
   34 if (( $# >= 6 )); 
then 
   42     fatal 
"Wrong number of arguments." 
   45 JPrintTree -
f $DAQ_FILE | 
awk '/KM3NETDAQ::JDAQSummaryslice/ {print $3}'  |  
read N 
   47 set_variable   RUNBYRUN             
"file=$DAQ_FILE; sampler=${SAMPLER%% *} $(($N / 2))" 
   52 JConvertDetectorFormat  -
a ${DETECTORA}  -
o ${DETECTORA_2}
 
   53 JConvertDetectorFormat  -
a ${DETECTORB}  -
o ${DETECTORB_2}
 
   55 # Procedure to determine optical modules with out-sync-problem. 
   56 # The given detector file is accordingly updated. 
   71 # Procedure to determine Jpp version used during data taking as default handling of UDP packet losses has changed. 
   72 # The given detector file is accordingly updated. 
   76 echo ${(s/./)DAQ_VERSION}                                            | 
read     DAQ_MAJOR DAQ_MINOR DAQ_PATCH
 
   78 if [[ 
"$DAQ_MAJOR" != [0-9][0-9]* ]] || (( $DAQ_MAJOR <= 12 )); 
then # Jpp-
version dependence
 
   80     notice 
"Set UDP counter and trailer disable." 
   84         -
P "-1 -1 set UDP_COUNTER_DISABLE"  \
 
   85         -
P "-1 -1 set UDP_TRAILER_DISABLE"  \
 
   93     -
f"${INPUT_FILES[*]}"         \
 
then usage $script< detector >< run >< outputfile > fi case set_variable OPTION
 
then usage $script< detector identifier >< startdate\"YYYY-MM-DDHH:MM:SS\"><finaldate\"YYYY-MM-DDHH:MM:SS\"><QA/QCfile> fi case set_variable QAQC_TXT $argv[4]
 
then fatal No hydrophone data file $HYDROPHONE_TXT fi sort gr k
 
&set_variable NUMBER_OF_TIMESLICES
 
std::istream & read(std::istream &in, JTestSummary &summary, const char delimiter= ' ')
Read test summary. 
 
o $QUALITY_ROOT d $DEBUG!CHECK_EXIT_CODE JPlot1D f
 
then fatal Wrong number of arguments fi JConvertDetectorFormat a o
 
then timer_start(JRandomTimesliceWriter-a ${DETECTOR}-o ${PIPE}-n ${NUMBER_OF_SLICES}-P ${PMT_FILE}-d ${DEBUG}-S ${SEED}-B"$BACKGROUND_HZ"-N"$RECYCLING"--!&&for((i=0;$i!=10;++i));do;echo 'EOF' > $PIPE;usleep 100000;done &&rm-f $PIPE)&JTimesliceReprocessor-a $
 
then echo Variable JPP_DIR undefined exit fi source $JPP_DIR setenv sh $JPP_DIR &dev null set_variable
 
do set_variable STRING_TXT awk
 
const JK40Rates & getK40Rates()
Get K40 rates. 
 
then echo Variable JPP_DIR undefined exit fi source $JPP_DIR setenv sh $JPP_DIR &dev null set_variable DEBUG set_variable WORKDIR
 
&set_variable OUTPUT_FILE
 
do sput $STRING $FLOOR sget MODULE INPUT_FILES
 
&set_variable OUT_FILE set_variable DETECTOR_FILE set_variable DAQ_FILE
 
then usage $script< input file >[option[primary[working directory]]] nWhere option can be N
 
fi set_variable FILENAME $WORKDIR
 
then JMuonMCEvt f $INPUT_FILE o $INTERMEDIATE_FILE d
 
source $JPP_DIR setenv csh $JPP_DIR &dev null eval JShellParser o a A
 
esac $JPP_BIN JLogger sh $LOGGER until pgrep JGetMessage</dev/null > dev null
 
#define DEBUG(A)
Message macros.