diff --git a/daq.sh b/daq.sh index 00e5a6c6870ab95df3880e63dafbfafa6e52233c..6ebc8f9492e7dcff63da4511be8cbd41b4362b74 100755 --- a/daq.sh +++ b/daq.sh @@ -38,6 +38,9 @@ DETECTOR=du1cppm.detx # position of the detector file ROOT_FILE=`printf "${DIR}/KM3NeT_%08d.root" ${RUN_NUMBER}` +# Run number formatted for filenames +RNUMB_FNAMES=`printf "%08d" ${RUN_NUMBER}` + if [ -f ${ROOT_FILE} ] ; then echo "The file ${ROOT_FILE} already exists, please rename or remove it first, then restart this script" exit -1 @@ -59,6 +62,8 @@ triggerParameters = writeTimeslices = 1; bufferSize = 1073741824; EOF +cp ev_configure_dfilter_dqdf.txt ${HOME}/.km3_private/ev_configure_dfilter_dqdf_R${RNUMB_FNAMES}.txt + cat>ev_configure_dqueue_dqdf.txt<<EOF timeslice_duration=100; run_start_time=${RUN_START_TIME}; @@ -71,6 +76,8 @@ opto_recipients=127.0.0.1:5556; acou_recipient=127.0.0.1:5800; EOF +cp ev_configure_dqueue_dqdf.txt ${HOME}/.km3_private/ev_configure_dqueue_dqdf_R${RNUMB_FNAMES}.txt + # Driver input cat>driver.txt<<EOF @@ -104,6 +111,8 @@ event ev_off { RC_CMD } EOF +cp driver.txt ${HOME}/.km3_private/driver_R${RNUMB_FNAMES}.txt + JDAQDriver -H $SERVER -M $LOGGER -d $DEBUG -t $TIMEOUT_S -f driver.txt -c exit 0