iMPACT
Programming an SPI or BPI Flash Memory through an FPGA
This procedure programs an SPI or BPI Flash memory through a Xilinx FPGA, using indirect programming.
For a detailed description of indirect programming, see these Xilinx Application Notes:
  •  Indirect Programming of SPI Serial Flash PROMs with Spartan®-3A FPGAs (XAPP974)
  •  Indirect Programming of BPI PROMs with Virtex®-5 FPGAs (XAPP973)
For information on SPI and BPI Flash memories that iMPACT supports and the Xilinx FPGAs that can be used for indirect programming of these Flash memories, see the tables in Introduction to Indirect Programming – SPI or BPI Flash Memory.
Before performing this procedure, you must be connected to the Xilinx FPGA and attached Flash memory through a Xilinx cable.
To Program an SPI or BPI Flash Memory through an FPGA
  1.  Create the PROM file for the Flash memory that will be programmed through the FPGA.
    The PROM file must be in .mcs or .exo format.
    For an SPI Flash memory, the procedure to create the PROM file is one of these:
    For a BPI Flash memory, the procedure to create the PROM file is one of these:
  2.  Select File > New Project or click the New Project toolbar button (Image) to create a new project for the indirect programming operation.
  3.  In the New iMPACT Project dialog box:
    1.  Select create a new project (.ipf).
    2.  Click the Browse button.
    3.  In the Create New iMPACT Project File dialog box, specify a directory and a file name for the project file and click Save.
    4.  Click OK.
  4.  In the Welcome to iMPACT dialog box, select Configure devices using Boundary-Scan (JTAG).
  5.  In the dropdown list, select Automatically connect to a cable and identify Boundary-Scan chain.
  6.  Click OK.
  7.  In the Assign New Configuration File dialog box, browse to the directory containing your configuration file, select the file name, and click Open.
  8.  In the dialog box asking Do you want to attach an SPI or BPI PROM to this device?, click Yes.
  9.  In the Add PROM File dialog box, select the PROM file format in the Files of type box, then browse to the appropriate directory and select your PROM file.
    The Select Attached SPI/BPI dialog box opens, containing a listing of the supported devices for the Flash memory you will program.
  10.  In the Select Attached SPI/BPI dialog box, specify the Flash memory type (SPI PROM or BPI PROM) and specify the other entries in the dialog box, including Data Width and Select RS[1:0]b Pin Address Bits, if applicable.
  11.  Click OK.
  12.  In the Device Programming Properties dialog box, specify the desired FPGA and Flash memory programming options.
    Note It is recommended that you select Erase Before Programming and Verify options for the attached Flash memory. This will ensure the Flash Memory is properly erased before programming and the contents have been verified for proper programming.
  13.  Click OK.
    The FPGA and attached Flash memory are displayed in the Boundary Scan window.
The result is:
  •  The existing design in the FPGA will be overwritten by the core to program the flash indirectly. Once the FPGA has been configured with the JTAG-to-SPI or JTAG-to-BPI core, the unused I/Os are set to PULLUP, activating the internal pull-up on the I/O.
  •  The Flash memory is programmed.
After programming, you can perform any available operations on the programmed SPI or BPI device.
See Also

© Copyright 1995–2009, Xilinx® Inc. All rights reserved.