This page describes the procedure for remote reflashing the System Board Igloo2 FPGA using WorldFIP.
prerequirements
- working masterfip (https://gitlab.cern.ch/cohtdrivers/masterfip)
instructions on how to run masterfip - https://ohwr.org/project/masterfip/wikis/installation-guide - SVF file (with gateware description)
- make sure the TRST signal is not pulled-down
building
cd tools/nfipjtag
make
usage
./nfipjtag_main.mfip [-i<INTERFACE>] [-b<BUS SPEED>] [-qdfr] [(-s | -x)] <ADDRESS> <FILE> [<FILE>...]
-1<WAIT1> Wait time (us) for RX ID_DAT
-2<WAIT2> Wait time (us) for end of cycle, relative to WAIT1
-t<SILENCE_TIME> Set silence time (us) (0-272)
-b<BUS SPEED> Select bus speed: 0=31.25 Kb/s, 1=1000 Kb/s, 2=2500 Kb/s (default)
-i<INTERFACE> FullFIP interface number (default 0)
-q Quiet mode - does not report progress
-d Debug mode - report extra debug information
-s | -x Select SVF file format (default) or XSVF file format
-r Control the JTAG TRST
-f Fast mode - do not check TDO, unreliable but faster programming
<ADDRESS> Target nanoFIP address
<FILE> SVF or XSVF file to process
e.g.
sudo ./nfipjtag_main.mfip -b2 -d 1 diot_hydra2_top_svf/diot_hydra2_top_VERIFY.svf
trst
To program the gateware correctly the trst jtag signal must be high, i.e. make sure that there is no resistor that pulls down the trst signal. In the FGC, the TRTS signal is driven by a modified version of nanofip (option -r). The current official version of nanoFIP does not drive the TRST line, so for reprogramming to work, the TRST signal cannot be pulled down. In future versions the nanoFIP will control TRST, so there will be no need to desolder the pull-down resistor.
fast mode (-f)
The fast mode allows to program the gateware up to 12 times faster.
Fast mode checks the TDO signal once every 63 TDO signals, so it may not detect all programming error.
Therfore this mode is for development purposes only.
e.g.
sudo ./nfipjtag_main.mfip -1640 -2200 -t116 -b2 -f -d 1 diot_hydra2_top_svf/diot_hydra2_top_VERIFY.svf
To speed up programming, the default macrocycle values might be changed to e.g. -1640 -2200 -t116
.