News:

Attention: For security reasons,please choose a user name *different* from your login name.
Also make sure to choose a secure password and change it regularly.

Main Menu

Help: Booting from DDR SDRAM

Started by MSN, December 23, 2011, 10:25:24 AM

Previous topic - Next topic

MSN

Hey

I am trying to make a FWU file for booting from DDR SDRAM, but I am totally lost.
It would be nice if you could make a complete guide on how to make a FWU file which boot from external memory.

I am using the TE0300-01BMLP board, and I have based my design on the TE0300-01_v7.0 example.

Please guide me through this.

-Martin

Ales Gorkic

Hi Martin,

The procedure for making the FWU with bootloader:
Compile demo sw project with start address which points to SDRAM start address. You can set this in sw project settings or with linker script. Download hardware and then load the demo sw with xmd (xmd.ini specifies which executable will be loaded). This way you verify that the program is working with you settings.
Then compile the bootloder program and mark the program to initialize BRAM. Download the merged bitstream to FPGA. The program will try to boot but will fail since the flash is empty.
Then run the PREPARE_FWU/copyandbuild_boot.bat which will generate FWU automatically.

Best regards,

Ales

MSN

Hey

I have my software project in SDK
In SDK I generate the linker script (all options set to DDR SDRAM).
From XPS I download the bitstream to the FPGA
Launch XMD and dow the elf file I generated in SDK, run. And I can verify that the program is working.

Super... maybe

but now I'm pretty lost, this is what i have tried:
I open the copyandbuild_boot.bat and change the destination and name of the elf file.

In XPS I select the microblaze_0_bootloop and "update bitstream with software program information", then I download the bitstream to the FPGA...
Then I run the copyandbuild_boot.bat. and download the generated "firmware.fwu" file with the USBFirmwareUpgradeTool. The download finish, but my program is not working  :'(

Thorsten Trenz

Hi,
is the program not working, or the FPGA not booting at all?
Did you set the startup clock to CCLK?

best regards
Thorsten Trenz


Ales Gorkic

#4
Hi Martin,

If you are using SDK please use the latest design from our SVN:
https://github.com/Trenz-Electronic/TE03XX-Reference-Designs/tree/master/reference-TE0300/

This one has updated scripts in the PREPARE_FWU folder. It is not just the copyandbuild_boot.bat, but also build_bram.bat and bit2bin.cmd.

This SDK_workspace contains two sw projects:
bootloader which should be marked to initalize BRAM
demo which is executed from DDR SDRAM.

The booting process:
1. Bootloader program reads the boot header from the FLASH
2. Bootloader copies demo executable from the FLASH to DDR.
3. Vectors are loaded from FLASH to BRAM (addr 0x0)
4. Executable checksum is verified
5. Demo program is executed from DDR SDRAM base address

Hope this answers your questions.

Best regards,

Ales


MSN

Thanks
But i am not able to open the project

WARNING:EDK:1687 - Invalid path specified for ModuleSearchPath in XMP file. Please make sure that the directory specified exists.
ERROR:EDK:4110 - IPNAME: xps_i2c_slave, INSTANCE: xps_i2c_slave_0 - cannot find MPD for the pcore 'xps_i2c_slave_v1_20_a' in any of the repositories - D:\reference-TE0300-01-ISE-13_2\system.mhs line 284
ERROR:EDK:4110 - IPNAME: xps_i2c_slave, INSTANCE: xps_i2c_slave_0 - cannot find MPD for the pcore 'xps_i2c_slave_v1_20_a' in any of the repositories - D:\reference-TE0300-01-ISE-13_2\system.mhs line 284
ERROR:EDK:4110 - IPNAME: xps_fx2, INSTANCE: xps_fx2_0 - cannot find MPD for the pcore 'xps_fx2_v1_30_a' in any of the repositories - D:\reference-TE0300-01-ISE-13_2\system.mhs line 310
ERROR:EDK:4110 - IPNAME: xps_npi_dma, INSTANCE: xps_npi_dma_0 - cannot find MPD for the pcore 'xps_npi_dma_v3_00_a' in any of the repositories - D:\reference-TE0300-01-ISE-13_2\system.mhs line 338
ERROR:EDK:4111 - IPNAME: xps_i2c_slave, INSTANCE: xps_i2c_slave_0 - cannot find MPD for the pcore - D:\reference-TE0300-01-ISE-13_2\system.mhs line 284
ERROR:EDK:4111 - IPNAME: xps_fx2, INSTANCE: xps_fx2_0 - cannot find MPD for the pcore - D:\reference-TE0300-01-ISE-13_2\system.mhs line 310
ERROR:EDK:4111 - IPNAME: xps_npi_dma, INSTANCE: xps_npi_dma_0 - cannot find MPD for the pcore - D:\reference-TE0300-01-ISE-13_2\system.mhs line 338
WARNING:EDK:3362 - Cannot open project due to errors.

Ales Gorkic

#6
Hi Martin,

You also need to download the custom core repository also:
https://github.com/Trenz-Electronic/TE-EDK-IP

If you organize folders in the same way as on the SVN then the project will find the cores automatically since the path is relative.
If not then you will have to point to the folder when asked.

When opening the SDK workspace you have to setup the repository path in any case. It should point to IpCores-ISE folder.

Best regards,

Ales