UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Adventurer
Adventurer
3,726 Views
Registered: ‎07-12-2012

Compact Flash programming questions

Hi there,

 

I am working with the ML605 board, ISE 13.3.

 

I want to store a bitstream in the CF memory when FPGA is active. I am reading DS617 and UG438 files. I have already managed to read and write from memory. Now, I would like to write in memory the bitstream, which will be provided by the user to the FPGA, but I have some doubts I would like to solve.

- Do I have to store the MCS file "raw" in the memory? Or just one "piece" of it? Or should I modify it in some way?

- Where do I have to store it? I am working in Slave SelectMap mode so, as far as I have understood from the documents, I should begin writting at address 0x000000 since there are pull-down registers in address bus.

 

That would be nice for beginning.

 

Thank you very much in advance,

 

Alberto

0 Kudos
4 Replies
Adventurer
Adventurer
3,725 Views
Registered: ‎07-12-2012

Re: Compact Flash programming questions

I don't know if I have explained well what I want to do. I want to store the bitstream without iMPACT tool, but taking control of the memory signals and writing bitstream data word by word in the memory.

0 Kudos
Xilinx Employee
Xilinx Employee
3,705 Views
Registered: ‎07-23-2012

Re: Compact Flash programming questions

If you are using Xilinx PROMs then refer to http://www.xilinx.com/support/documentation/application_notes/xapp058.pdf

If you are using SPI flash then refer to http://www.xilinx.com/support/documentation/application_notes/xapp1020.pdf
-----------------------------------------------------------------------------------------------
Please mark the post as "Accept as solution" if the information provided answers your query/resolves your issue.

Give Kudos to a post which you think is helpful.
0 Kudos
Instructor
Instructor
3,701 Views
Registered: ‎08-14-2007

Re: Compact Flash programming questions

I'm going to preface this by saying I haven't used CF for configuration before, so I may be off base.  However, generally you don't store the .mcs file "as is" into any coniguration memory.  The .MCS format is first of all ASCII hex (meaning two 8-bit characters per 8 bits of data), and secondly contains addressing information and checksums.  All you really want in the configuration memory is the actual bitstream data.  You could probably go on line and find software that reads .MCS files and makes a simple binary from it.  However you can also get the data directly by generating a .bin file when you run BitGen to create the .bit file.  If your .mcs file contains more than just the bitstream, for example ELF data for a microblaze, then it may also contain gaps between valid data locations.  In this case you would need to decode the .MCS file to determine where to write data within the CF card.  You could also write your own code to deal with the .MCS format, which is available on line if you google (I'd actually start at Wikipedia).

 

There's one case where you don't just use the .bin file when programming a bitstream into flash.  That's when the data from the flash device comes out serially LSB first.  This was true of early Xilinx PROMs.  The .bit and .bin files are generated such that the MSB should shift out first, so you'd need bit swapping when programming the flash.  SPI serial flash outputs the MSB first so it doesn't require swapping.  I was under the impression that CF cards are parallel out only, so you'd need to check whether your programming method (SelectMap?) requires bit swapping.

-- Gabor
0 Kudos
Moderator
Moderator
3,691 Views
Registered: ‎01-15-2008

Re: Compact Flash programming questions

Alberto,

 

CF generally is programmed with  .ace file format with CF card reader

http://www.xilinx.com/support/documentation/boards_and_kits/xtp055.pdf

You will use impact for converting .bit to .ace format. The .ace file will be programmed to CF and this configures the fpga.

http://www.xilinx.com/support/documentation/data_sheets/ds080.pdf

The following application notes discusses on this file .ace file format, this might be of helpful in understanding and use in your design to write the config file(.ace)

http://www.xilinx.com/support/documentation/application_notes/xapp424.pdf

 

Hope this will help you to proceed.

 

--Krishna 

0 Kudos