[ << Motherboard Re-Clocking | ^ Top ^ | Timing Latency >> ]

FPGA Bit Stream Questions

  • How the USRP FPGA configuration bit stream file loaded?

When using GNU Radio USRP functions, the host library takes care of loading the “.rbf” file into the FPGA for you. This takes place over the USB.

However, you can manually load the .rbf using the usrper command:

 $ usrper --help 
 usage: 
   usrper [-v] [-w <which_board>] [-x] ... 
   usrper load_standard_bits 
   usrper load_firmware <file.ihx> 
   usrper load_fpga <file.rbf> 
   usrper write_fpga_reg <reg8> <value32> 
   usrper set_fpga_reset {on|off} 
   usrper set_fpga_tx_enable {on|off} 
   usrper set_fpga_rx_enable {on|off} 
   ----- diagnostic routines ----- 
   usrper led0 {on|off} 
   usrper led1 {on|off} 
   usrper set_hash0 <hex-string> 
   usrper get_hash0 
   usrper i2c_read i2c_addr len 
   usrper i2c_write i2c_addr <hex-string> 
   usrper 9862a_write regno value 
   usrper 9862b_write regno value 
   usrper 9862a_read regno 
   usrper 9862b_read regno 
 $ usrper load_fpga <name of your .rbf file> 

will load the .rbf file into the FPGA. Please note that it is possible to permanently damage the USRP by loading buggy code into the FPGA.

  • When we program the FPGA using python programs (eg. usrp_fft.py), are the same .rbf files generated? Where?

The files aren't generated, they are loaded. By default, an rbf is loaded from /usr/local/share/usrp/rev{2,4}. The one used unless you specify the fpga_filename constructor argument when instantiating a usrp source or sink is std_2rxhb_2tx.rbf. FYI, we load std.ihx, standard firmware for the Cypress FX2 USB controller, before loading the FPGA .rbf file. We load the FX2 firmware over the USB. That firmware implements additional control endpoint commands, including those that know how to load an .rbf into the FPGA.

[ << Motherboard Re-Clocking | ^ Top ^ | Timing Latency >> ]