Skip to content

Commit b8974ea

Browse files
chiarazampollishahor02
authored andcommitted
Passing workflow as argument to script to simulate multiple EPNs
1 parent 2f95918 commit b8974ea

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,19 @@
11
#!/bin/bash
22

3+
4+
if [ $# -lt 2 ]; then
5+
# if there is no workflow passed, we pass a "default" one
6+
cmd="o2-calibration-data-generator-workflow --lanes 7 --gen-slot $iEPN --gen-norm 3 --mean-latency 100000 --max-timeframes 500 -b | o2-dpl-output-proxy --channel-config "name=downstream,method=connect,address=tcp://localhost:30453,type=push,transport=zeromq" --dataspec downstream:TOF/CALIBDATA -b ; exec bash"
7+
else
8+
cmd=$2
9+
fi
10+
311
iEPN=0
412
xpos_start=100
513
while [[ $iEPN -lt $1 ]]
614
do
715
echo $iEPN
816
xpos=$((xpos_start+1000*$iEPN))
9-
xterm -hold -geometry 150x41+$xpos+300 -e bash -c "o2-calibration-data-generator-workflow --lanes 7 --gen-slot $iEPN --gen-norm 3 --mean-latency 100000 --max-timeframes 500 -b | o2-dpl-output-proxy --channel-config "name=downstream,method=connect,address=tcp://localhost:30453,type=push,transport=zeromq" --dataspec downstream:TOF/CALIBDATA -b ; exec bash" &
17+
xterm -hold -geometry 150x41+$xpos+300 -e bash -c "${cmd}" &
1018
((iEPN = iEPN +1 ))
1119
done

0 commit comments

Comments
 (0)