cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
golson
Scholar
Scholar
4,628 Views
Registered: ‎04-07-2008

Is there a big difference between using Impact to download Download.bit and EDK?

Jump to solution

Hi,

  We are trying to download the download.bit file using Impact to see if the Software Program will begin to execute after download has completed.

The Processor does not start and run the program after the Impact has finished downloading the Download.bit file.

 

However if we use the EDK to download the bitstream.  The processor will execute the code after downloading.

 

 

We tested the download.bit download using impact to see if it really downloaded the file by bringing up xmd to download a software app and run it.

This worked using XMD telling me that the system was configured ok but for some reason the software program will not execute.

 

Thank You,

 Gary

 

0 Kudos
1 Solution

Accepted Solutions
golson
Scholar
Scholar
5,751 Views
Registered: ‎04-07-2008

Found the solution after getting PROGRAM FLASH MEMORY option to work.  We noticed the note that says

you must download the bitstream to the FPGA before trying to Program Flash Memory using the option in EDK.

 

If you don't download the bitstream first we were getting to CFI Query and then getting stuck at that point.  Once

we started by downloading the bitstream then the Program Flash memory succeeded.

 

This is not exactly what we wanted to do though.  We want to use the Platform Flash to hold the System.bit file and the Software too.

Of course the Download.bit file held the software and the system.bit file.  But for some reason it was not executing the code.

 

So I looked at the bootloader project and saw in the Compiler settings the difference.  You need to set the compiler setting

to use default linker script checked and set the PROGRAM START ADDRESS 0xFFFFC000 in my case.

 

That is the start of the BRAM address so that the code will be executed.  After doing this we got the code to execute.

 

View solution in original post

0 Kudos
5 Replies
pcurt
Explorer
Explorer
4,621 Views
Registered: ‎04-09-2008

The download.bit you are loading probably contains most of your configuration information, but lacks the BlockRAM initialization, which contains your compiled C code.  The system.bit file in the implementation directory contains your raw bitstream.  You must run the data2mem utility to combine this .bit file with a compiled .elf and generate a new .bit file.

 

Normally I use SDK to do this for me automatically, not XPS.  In XPS, I think you can check something like "Mark to Initialize BlockRAM."  Then when you download the bitstream, XPS should run data2mem with your application and store the resulting bitfile somewhere.  You'll need to look around in your directory structure to figure out where it puts that temporary file.

 

In SDK, I know that you can select "Tools->Program FPGA."  Select the Initialization ELF, then click "Save."  SDK produces a file called "download.bit" in the .metadata directory, which is the file you wan to download with Impact.

 

Keep in mind that in order for this to work all of your compiled code must fit into the local BlockRAM within the chip.  If your program is too large and you are forced to move sections of your data or code into external memory, you will need to use something like SystemACE.

0 Kudos
golson
Scholar
Scholar
4,587 Views
Registered: ‎04-07-2008

Thank You for your response,

 

It is hard to be sure if the bitstream contains the software.  But the Console program sent out a log file indicating the

data2mem command was used and it also indicates inclusion of the Simple Hello World program that I was using for

testing.

 

I kept trying to day to get it to work.  But it still does not work today.  I believe it is downloading the system.bit file.

but I have to bring up XMD and download the software separately to see any output on the RS232 monitor.

 

 

I also tried to Use the PROGRAM FLASH MEMORY to see if I could use this option.  But the program gets stuck trying to

query CFI.

 

 

0 Kudos
xiaofeip_dup
Xilinx Employee
Xilinx Employee
4,576 Views
Registered: ‎08-07-2007

Hi ,

 

There's no difference between downloading wiht iMPACT GUI or withing EDK. EDK actually downloads a bitstream with iMPACT in batch mode. The iMPACT batch file that being used by EDK is the "download.cmd" file.

 

To verify whether the bitstream has been initialized properly with the applciaton code, yo ucan dump the bitstream with "data2mem" tool with "-d" switcc, as described in http://www.xilinx.com/support/answers/24714.htm.

 

-Felix

0 Kudos
golson
Scholar
Scholar
4,570 Views
Registered: ‎04-07-2008

I will try the dump command.  I tried yesterday but could see there was a lot of hex numbers in the file still was not sure if the data was

the program or not.

 

So if the download.bit file does contain the program.  And I download the program to the platform flash.  Then power down the board.

and turn the power on the board.  I expect the platform flash bring up the FPGA.  will the FPGA execute the program that should be in

the BRAM without any interaction from me?  Or do I need to press the reset button?

 

 

By the way, the EDK download does not execute the program either.  What was happening was that there was a executable file

in the Compact Flash which would execute confusing the issue.

 

 

Thank You,

  Gary

 

 

0 Kudos
golson
Scholar
Scholar
5,752 Views
Registered: ‎04-07-2008

Found the solution after getting PROGRAM FLASH MEMORY option to work.  We noticed the note that says

you must download the bitstream to the FPGA before trying to Program Flash Memory using the option in EDK.

 

If you don't download the bitstream first we were getting to CFI Query and then getting stuck at that point.  Once

we started by downloading the bitstream then the Program Flash memory succeeded.

 

This is not exactly what we wanted to do though.  We want to use the Platform Flash to hold the System.bit file and the Software too.

Of course the Download.bit file held the software and the system.bit file.  But for some reason it was not executing the code.

 

So I looked at the bootloader project and saw in the Compiler settings the difference.  You need to set the compiler setting

to use default linker script checked and set the PROGRAM START ADDRESS 0xFFFFC000 in my case.

 

That is the start of the BRAM address so that the code will be executed.  After doing this we got the code to execute.

 

View solution in original post

0 Kudos