From 444d9171c2a938737655e5bc61a40f095e8fda5c Mon Sep 17 00:00:00 2001 From: Boudewijn Hut <hut@astron.nl> Date: Fri, 3 Nov 2017 13:09:23 +0000 Subject: [PATCH] Added functionality to get PPS delays from MACs configuration file (only for 'apertif-sr2.6') --- .../apertif/commissioning/dish_commands.sh | 36 ++++++++++++------- 1 file changed, 24 insertions(+), 12 deletions(-) diff --git a/applications/apertif/commissioning/dish_commands.sh b/applications/apertif/commissioning/dish_commands.sh index d7ddc741cc..5a8e6211f1 100755 --- a/applications/apertif/commissioning/dish_commands.sh +++ b/applications/apertif/commissioning/dish_commands.sh @@ -250,8 +250,18 @@ python $UPE/peripherals/util_diag_wg_wideband.py --unb $UNBS --bn 0:3 -n 4 --sp # equals difference in cable length in meters. FIXME Disabled due to buggy bn_filterbank image ############################################################################### #if [ "$(hostname)" != "lcu-rtc" ] && [ "$(hostname)" != "lcu-rtd" ]; then +# Inital values for RTC, RTD: # python $UPE/peripherals/pi_common_pulse_delay.py --unb $UNBS --bn 0:3 --reg pulse_delay=1516 #fi +if [ "$APP" == "apertif-sr2.6" ]; then +# . Determine telescope character (2..D) + HOST=$(hostname) + TELCHAR=${HOST:6:7} +# . Get value from MAC configuration file + PPS_DELAY=$(grep -i RT$TELCHAR /opt/apertif/etc/FixedDelays.conf | awk -v N=$3 '{print $3}') +# . Apply value + python $UPE/peripherals/pi_common_pulse_delay.py --unb $UNBS --bn 0:3 --reg pulse_delay=$PPS_DELAY +fi ############################################################################### # Write fiber delay setting. @@ -274,18 +284,20 @@ python $UPE/peripherals/util_diag_wg_wideband.py --unb $UNBS --bn 0:3 -n 4 --sp # . RTC: 2274m 0m # . RTD: 2274m 0m ############################################################################### -#case "$(hostname)" in -# lcu-rt2) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1188 ;; -# lcu-rt3) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1288 ;; -# lcu-rt4) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1384 ;; -# lcu-rt5) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1499 ;; -# lcu-rt6) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1533 ;; -# lcu-rt7) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1429 ;; -# lcu-rt8) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1325 ;; -# lcu-rt9) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1222 ;; -# lcu-rta) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1099 ;; -# lcu-rtb) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1099 ;; -#esac +if [ "$APP" == "apertif-sr2.6" ]; then + case "$(hostname)" in + lcu-rt2) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1188 ;; + lcu-rt3) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1288 ;; + lcu-rt4) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1384 ;; + lcu-rt5) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1499 ;; + lcu-rt6) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1533 ;; + lcu-rt7) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1429 ;; + lcu-rt8) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1325 ;; + lcu-rt9) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1222 ;; + lcu-rta) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1099 ;; + lcu-rtb) python $UPE/peripherals/pi_dp_fifo_monitor.py --unb $UNBS --fn 0:3 --reg rd_fill=1099 ;; + esac +fi ############################################################################### # Write front end beamformer settings for Arts SC1: -- GitLab