#!/bin/bash
echo "The switch needs to be power cycled after fpga update."
PROMPT="Do you want to update the FPGA [N] "
while true
do
 read -ep "$PROMPT" REPLY
 case `echo $REPLY | /usr/bin/tr [:lower:] [:upper:]` in
  N|NO|"") exit 0 ;;
  Y|YES) break ;;
 esac
done
echo "Please avoid powering off the switch during programming."
echo "After JTAG programming is complete, please power cycle the switch!"
echo ""
/fabos/share/jtagpgm -f /fabos/share/F3_sysFPGA.xsvf
