SPI Flash on Avnet Spartan 3E Eval Kit

Do you have a question? Post it now! No Registration Necessary

Translate This Thread From English to

Threaded View

Any good ideas for how to program the the SPI Flash on the Avnet Spartan
3E Evaluation Kit?

The Avnet instructions for generating the HEX file which they wrote for
ISE 7.1 don't work in ISE 8.2.03i WebPack.  I get an ERROR: Bitstream:44
message and no HEX file.  Any other file format which I generate with
iMPACT loads into the SPI according to the Avnet utility, but the FPGA
does not get configured after reconfiguring the jumpers and re powering
the board.

I have the Xilinx Platform Cable USB so was unable to try the Universal
Scan demo.

Xilinx support pointed out the XAPP445 App Note and xspi_usb utility.
This program doesn't work, or I am doing something wrong.

My command line:
xspi_usb -spi_dev m25p40 -spi_epv -mcs -i promdata.mcs -o output.txt

and the error is:
==> Checking SPI device [STMicro_M25P40_ver_00100] ID code(s)
    - density = [524288] bytes
              = [4194304] bits
    - density_code = [0xFF] ==> error: expected [0x12]

On my board I have replaced the PROM for the Cypress USB Controller with
  QuickUSB from Bitwise Systems.  By replacing the 0 ohm resistor on the
PROM E0 line with a jumper I can choose to power up with or without the
QuickUSB firmware.  Without QuickUSB it starts up as a Cypress device
with no PROM and the Avnet utility seems to still work.  I can use it to
  configure the FPGA but haven't been able to program the SPI Flash as
mentioned above.  I have been using the Platform Cable USB to configure
the FPGA, but now my design is working I need to make it permanent.



Re: SPI Flash on Avnet Spartan 3E Eval Kit

You can use picoblaze to program the SPI flash.

Try this one :
in PicoBlaze SPI Flash Programmer

It works for Spartan-3E Starter kit, but I don't know whether it works
for your board.

Re: SPI Flash on Avnet Spartan 3E Eval Kit
Quoted text here. Click to load it

I was looking for a quick solution.  Since I don't have the same board
as that app note and I have never worked with the picoblaze, this looks
like a steep learning curve.

I have been trying the Xilinx xspi_usb utility, but it has problems with
the device id.  If I tell it not to check the device id it fails on the
bulk erase.

If I use imPACT, Direct SPI Configuration, it also fails on device

Xilinx has been working on this problem for several days now, and they
still don't have an answer for me.

I could buy a module for the Advin programmer we have, but this seems a
little excessive for programming one chip, one time.

Is there a way to generate a HEX file that is compatible with the Avnet
utility using iMPACT 8.2.03i?

I spent a couple hours last weekend on my home computer, trying to get
ISE 7.1 to work, but Corgen wouldn't work so I couldn't get my design to
the point where I could follow the procedure in the Avnet documentation.

The reason for purchasing the Avnet board is that it was much cheaper
then doing my own board and I thought it would be much quicker.  Usually
we do our own boards and use the XC18V02 PROMS.  What I need is a board
with the Cypress USB Microcontroller and an FPGA.

Looks like I have to spend the weekend building a programmer for the ST
25P40PV.  Alternatively tell my boss I wasted the last month, fire up
Mentor Graphics and do my own board.


Re: SPI Flash on Avnet Spartan 3E Eval Kit
While playing around with the Avnet utility that came with the
Evaluation Kit, I discovered that doing a bulk erase of the SPI Flash,
makes it possible to write to it.

It would have been nice if Avnet had mentioned this in their
documentation, for guys like me who are don't always think of the obvious.

Xilinx also needs to fix ISE/iMPACT 8.2, so that it can generate HEX
file for this PROM.  For now you need to use ISE/iMPACT 7.1 to generate
these files.  With a few bug fixes in ISE/iMPACT 8.2 and the xspi_usb
program, you could use one of them for programming the SPI Flash.

Xilinx support tried their best to help me.  When opening a Web Case at
Xilinx I choose to interact by email.  This resulted in trying one thing
per day.  Interaction by phone would have had a faster turn around time,
but I don't know if that would have helped since I found the problem
myself eventually.

Avnet support ignored me.

I might use the Avnet Spartan 3E Evaluation Kit again, because it is
cheap and I now know how to make it work.  Adding a QuickUSB PROM from
Bitwise Systems, does increase the cost a little.  QuickUSB is needed
because the Cypress firmware and Windows device driver is useless.  I
also have an Opal Kelly board on order.  If that works well I might use
those for future projects instead.


Re: SPI Flash on Avnet Spartan 3E Eval Kit
i had the same troubles (but with ISE 8.1).
i found i can generate the hex files in command line :
promgen -w -p hex -c FF -o fichier.hex -u 0 fichier.bit -b

let me know if it works for you

( to bad that AVNET doesnt have o correct support ! we could gain a lot
of time )

Re: SPI Flash on Avnet Spartan 3E Eval Kit
Quoted text here. Click to load it

Thanks for the information, but I can't really try your suggestion now.
  I got things working by having someone else generate the Hex file for
me in ISE 7.1.  Now the board is being used for its intended application
and I don't want to mess with it.  Since then I have been working on the
software that runs on Windows which communicates with Avnet board.  If
and when I do another FPGA project I might use an Opal Kelly board
instead.  I have one at home so I might be playing with it soon.

Photos of my project with the Avnet board can be found at:


Site Timeline