Reply
Visitor
Posts: 1
Registered: ‎05-07-2012

programming a BPI Flash

Hello,

we have Avnet Spartan-6 LX150T Development Kit board. and we wanted to programm the FPGA from our BPI flash (parallel NOR flash) but it doesn't work. The problem is that the FPGA_CS (cheap select) is not connected with Flash_CE (Cheap enable) like in the documentation.

so we took the 2 X flashs and we made a bridge for the JTAG so that we have only the FPGA and the BPI flash. than we connect FPGA_CS (cheap select) with Flash_CE (Cheap enable) like in the documentation. But it doesnt work. We think that the problem is: the Vector A[0..24] is bad connected in the FPGA! (Bank2). is it? do you have solutions?

help please and thanks Smiley Happy

Avnet Employee (Star Contributor)
Posts: 511
Registered: ‎05-05-2009

Re: programming a BPI Flash

Parallel Flash on this board is not used for configuring the FPGA, hence, it is not fully connected to the BPI pins of the FPGA. The FPGA configuration on this board is done using the Platform Flash XCF32P and XCF08P devices. The parallel Flash on this board can be used to store processor code/data for embedded applications. This Flash can be programmed using the SDK Flash programmer. Please take a look at the "Embedded Example Design" for this board on our web site www.em.avnet.com/spartan6lx150t-dev (once on this page, click on the "Support Files & Downloads".

Regular Visitor
Posts: 5
Registered: ‎12-18-2013

Programming BPI Flash Memory

Hello,


I have bought a Xilinx Spartan-6 LX150T Development Kit, and try to use the Flash Memory on the board in my design. First, I need to initialize the Flash Memory. Could you please advise me how to create the initialization file and how to process the memory initialization?

 

Thank you,

 

Shuli

 

 

 

Avnet Employee (Star Contributor)
Posts: 511
Registered: ‎05-05-2009

Re: programming a BPI Flash

You have two options for programming the parallel Flash on the S6LX150T board:

 

1) Use the Flash programmer in the SDK tool to program the parallel Flash. The "Embedded Example Design" for the S6LX150T board on our web site www.em.avnet.com/spartan6lx150t-dev provides instructions on how to program the Flash using the SDK Flash programmer.


2) If you need to program the parallel Flash from within your main program, you would need to use the xilflash library. To use the xilflash library, you need to add the library to your BSP. Simply edit the BSP in SDK and add the xilflash to it. The EDK software folder in your EDK install directory has a few examples you can use to access the Flash device. These examples are located in the <EDK>/sw/lib/sw_services/xilflash_<version number>/examples folder.

Regular Visitor
Posts: 5
Registered: ‎12-18-2013

Re: programming a BPI Flash

Good morning!

 

Thank you for your response.

 

I have used iMPACT in ISE tool to download my design into the FPGA. It allows me to attach a BPI Flash Memory and download a .bit file into the menory. However, I don't know how to create the .bit file based on my data. Do you mean I can generate this file using SDK tool? If I have the initialization data such as:

......

 

0000001100110011
0000001100110011
0000001100110011
0000001100110011
0000010000000000
0000010000000000
0000010000000000
0000010000000000
0000010000000000

......

Could you please give me an example of the .bit file used for programming the BPI Flash?

 

Thank you,

 

Shuli

Avnet Employee (Star Contributor)
Posts: 511
Registered: ‎05-05-2009

Re: programming a BPI Flash

There is no BPI Flash on this board and you cannot use the parallel Flash on this board for configuring the FPGA. There are two platform Flash devices (XCF08 and XCF32) on this board that are used for FPGA configuration. You can only place a processor code and data into the parallel Flash for the purpose of booting the processor, not a bit file. Can you tell us how you are planning on using the parallel Flash on this board?

Highlighted
Regular Visitor
Posts: 5
Registered: ‎12-18-2013

Re: programming a BPI Flash

How about the "32 MB Flash" on the board?

 

I read the infor from the kit user guide on page 19 with Rev D 1.2, 12/14/2010:

 

The Flash memory consists of a single 32 MB Spansion S29GL-P device in a 64 ball BGA package, part number
S29GL256P11FFIV10. The S29GL-P device is an asynchronous memory that also supports a synchronous-burst read mode
for high-performance applications. The S29GL-P device has a 110 nanosecond access time. The S29GL-P flash connects to
pins in Banks 1 and 2 of the Spartan-6 FPGA.

 

Figure 10 in this user guide shows the interface between Spartan-6 and the Flash.

Avnet Employee (Star Contributor)
Posts: 511
Registered: ‎05-05-2009

Re: programming a BPI Flash

Yes, we do have 32MB of parallel Flash on this board that can be used to boot a processor such as MicroBlaze in an embedded design, but this Flash cannot be used to configure the FPGA. 

Regular Visitor
Posts: 5
Registered: ‎12-18-2013

Re: programming a BPI Flash

Can I read and write this Flash from FPGA if I connect the data bus and the control signals betteen FPGA and the Flash?

 

In my design, first I neet to store the data in the Flash, then I will read or write a 16-bit data at one clock cycle. The address of the cell of the Flash that will be read or writen is generated by my design downloaded in the FPGA. Do you think it is possible to use this Flash to finish my work? For your reference,  I have attached part of my bit file that should be initialized in the Flash. 

 

Thank you.

Avnet Employee (Star Contributor)
Posts: 511
Registered: ‎05-05-2009

Re: programming a BPI Flash

As I said before, you have two options for programming the parallel Flash on this board with your intial data&colon;

 

1) Use the Flash programmer in the SDK tool to program the parallel Flash. The "Embedded Example Design" for the S6LX150T board on our web site www.em.avnet.com/spartan6lx150t-dev provides instructions on how to program the Flash using the SDK Flash programmer. SDK Flash programmer uses SREC data as input, so you could convert your data into SREC format and use the Flash programmer to program the parallel Flash.


2) If you need to program the parallel Flash from within your main program, you would need to use the xilflash library. To use the xilflash library, you need to add the library to your BSP. Simply edit the BSP in SDK and add the xilflash to it. The EDK software folder in your EDK install directory has a few examples you can use to access the Flash device. These examples are located in the <EDK>/sw/lib/sw_services/xilflash_<version number>/examples folder.

 

In both cases, your best option would be to use a MicroBlaze based design to program the parallel Flash.