Initial FPGA Build Issues

Applications, development tools, FPGA, C, WEB
Post Reply
dsan
Posts: 2
Joined: Wed Jan 28, 2015 4:54 am

Initial FPGA Build Issues

Post by dsan » Wed Jan 28, 2015 5:12 am

Hello all,

I am having an issue getting the example base FPGA code up and running. What I am attempting to do is compile the FPGA code from the git-repo and then use the resulting red_pitaya_top.bin file rather than the boot.bin file from the dropbox sd card zip.

I successfully downloaded the git repo and compiled the FPGA code using Vivado 13.3 on an Ubuntu platform.
The resulting red_pitaya_top.bin file is 2,023kb.

However, the boot.bin file from the drop box location listed in the manual is 2,370kb.

I was expecting these to be the same size. Can someone please help?

Thank you,
Dave

Nils Roos
Posts: 1441
Joined: Sat Jun 07, 2014 12:49 pm
Location: Königswinter

Re: Initial FPGA Build Issues

Post by Nils Roos » Wed Jan 28, 2015 2:16 pm

Hi Dave,

The compiled fpga code is just one of three components that make up the boot.bin file. The other two are the first stage boot loader (fsbl) and the u-boot (second stage-) boot loader.
If you want to test your compiled fpga design, you can convert it into a prom file and load it from the console via /dev/xdevcfg (see eg this thread).

If you want the new design to be active at boot-time you need to build it into the boot.bin and replace the one on the SD card. To just create the boot.bin you can make the target "build/boot.bin" from the Red Pitaya top level directory.

Cheers
Nils

dsan
Posts: 2
Joined: Wed Jan 28, 2015 4:54 am

Re: Initial FPGA Build Issues

Post by dsan » Thu Jan 29, 2015 10:54 pm

Thanks Nils, that worked perfectly.

Dave

willsor
Posts: 3
Joined: Thu Jun 04, 2015 9:18 am

Re: Initial FPGA Build Issues

Post by willsor » Tue Jun 16, 2015 12:20 pm

Apologies for the necro, but I'm in a similar situation so I thought a new thread might be excessive.. Nils, how exactly does one 'build the FPGA bin file into the boot.bin" to get the fpga bin file to auto run at startup. I am working on windows, using Vivado, and used win scp with it's built in command line to transfer the fpga.bin file to xdevcfg to get it to run once


Cheers

Nils Roos
Posts: 1441
Joined: Sat Jun 07, 2014 12:49 pm
Location: Königswinter

Re: Initial FPGA Build Issues

Post by Nils Roos » Wed Jun 17, 2015 9:39 pm

You need the before-mentioned three components (fsbl.elf, red_pitaya_top.bit and u-boot.elf) to generate a new boot.bin.

The tool to build the boot.bin is included in the Xilinx SDK.

Once you have the three components ready, execute the following (add paths as neccessary)

Code: Select all

<path to SDK>\2013.3\settings64.bat
echo img:{[bootloader] fsbl.elf red_pitaya_top.bit u-boot.elf} > b.bif
bootgen -image b.bif -w -o i boot.bin
If you can't - or don't want to - build the fsbl and u-boot yourself, you can try decomposing the original boot.bin.
There is no "official" way to do that, but I had a look around, and it seems that the code in this repository, specifically dumpbootbin.c and bootdef.h, would do the right thing.
The code takes a boot.bin and separates it into it's constituent partitions. The generated files xxdump[1..3].dump should be the fsbl, bitstream and u-boot (in that order).

willsor
Posts: 3
Joined: Thu Jun 04, 2015 9:18 am

Re: Initial FPGA Build Issues

Post by willsor » Thu Jun 18, 2015 9:53 am

Sorry, but where exactly do I find these files fsbl.elf and u-boot.elf.. ?
I'm quite new to the red pitaya, and the only thing I've really familiar with is writing Verilog, I'm quite lost when it comes to booting stuff on red pitaya's linux environment :?

Nils Roos
Posts: 1441
Joined: Sat Jun 07, 2014 12:49 pm
Location: Königswinter

Re: Initial FPGA Build Issues

Post by Nils Roos » Tue Jun 23, 2015 7:26 pm

You could use these.

willsor
Posts: 3
Joined: Thu Jun 04, 2015 9:18 am

Re: Initial FPGA Build Issues

Post by willsor » Wed Jun 24, 2015 8:19 am

Thanks very much for putting those in a zip for me Nils,

managed to get it to work :D

Post Reply
jadalnie klasyczne ekskluzywne meble wypoczynkowe do salonu ekskluzywne meble tapicerowane ekskluzywne meble do sypialni ekskluzywne meble włoskie

Who is online

Users browsing this forum: No registered users and 25 guests