Issues loading .bit file on FPGA

dedicated to the FPGA topics for all Red Pitaya programmers
sourabh-ch
Posts: 2
Joined: Wed Mar 22, 2023 10:38 am

Issues loading .bit file on FPGA

Post by sourabh-ch » Wed Mar 22, 2023 3:57 pm

Hi,

I am having issues loading my programs on RP 125-14 after upgrading to the Unified OS 2.0

I used the same method to load the file as in the previous OS.

cat root/<file_name>.bit > /dev/xdevcfg

And there is no result of using the above command. Will this be fixed or should I keep using the old OS for this device ?

Thanks

juretrn
Posts: 104
Joined: Tue Nov 16, 2021 11:38 am

Re: Issues loading .bit file on FPGA

Post by juretrn » Wed Mar 22, 2023 6:56 pm

Hi, the new OS among other things uses a new mechanism of loading FPGA.
It is done as:

Code: Select all

fpgautil -b filename.bit.bin
The FPGA image must also be compiled in a slightly different way so it's compatible:

Code: Select all

	echo -n "all:{ path/to/bitfile/fpga.bit }" >  path/to/biffile/fpga.bif
	bootgen -image path/to/biffile/fpga.bif -arch zynq -process_bitstream bin -o path/to/binfile/red_pitaya.bit.bin -w

sourabh-ch
Posts: 2
Joined: Wed Mar 22, 2023 10:38 am

Re: Issues loading .bit file on FPGA

Post by sourabh-ch » Thu Mar 23, 2023 12:03 pm

Thank you !

I could not find that in the documentation, is there any place where I can clearly see the major changes ?

pavel
Posts: 790
Joined: Sat May 23, 2015 5:22 pm

Re: Issues loading .bit file on FPGA

Post by pavel » Thu Mar 23, 2023 1:35 pm

juretrn wrote:
Wed Mar 22, 2023 6:56 pm
Hi, the new OS among other things uses a new mechanism of loading FPGA.
This is great news! This means that all my applications that I uploaded to the application marketplace are rendered unusable with this new release. Well done Red Pitaya!

sslerose
Posts: 34
Joined: Sat Nov 26, 2022 12:43 am

Re: Issues loading .bit file on FPGA

Post by sslerose » Fri May 19, 2023 5:43 pm

sourabh-ch wrote:
Thu Mar 23, 2023 12:03 pm
Thank you !

I could not find that in the documentation, is there any place where I can clearly see the major changes ?
I have been in contact with one of the technical specialists and as far as I know they are working on the new documentation. From what I have gathered looking through their GitHub, one of the other major changes has been consolidating the build scripts into one .sh file that you just have to edit depending on which board you have (see this commit). They have also added a "zip_fpga" mode, but I am not sure what that will be used for.

There is also a change in how to roll-back your Red Pitaya after implementing a bit file. Instead of calling

Code: Select all

redpitaya> cat /opt/redpitaya/fpga/fpga_0.94.bit > /dev/xdevcfg
you need to call

Code: Select all

redpitaya> overlay.sh v0.94
They haven't even released the new OS for beta testing, so I wouldn't get your hopes up on documentation coming soon, it is a small team after all.

Mattias
Posts: 4
Joined: Sun Aug 06, 2023 7:44 pm

Re: Issues loading .bit file on FPGA

Post by Mattias » Mon Aug 14, 2023 10:06 am

Hello, how can I make the settings in vivado to create the *.bin file. How can I then load my own fpga image? With petalinux I can run fpgautil -b *.bin. But not here.
I wonder...
Thanks

juretrn
Posts: 104
Joined: Tue Nov 16, 2021 11:38 am

Re: Issues loading .bit file on FPGA

Post by juretrn » Wed Aug 16, 2023 8:23 am

Official FPGA images are loaded using the script overlay.sh .
This includes the line

Code: Select all

/opt/redpitaya/bin/fpgautil -b $FPGAS/$MODEL/$1/fpga.bit.bin -o $FPGAS/$MODEL/$1/fpga.dtbo -n Full
Your command should then be

Code: Select all

/opt/redpitaya/bin/fpgautil -b path_to_file.bit.bin

Mattias
Posts: 4
Joined: Sun Aug 06, 2023 7:44 pm

Re: Issues loading .bit file on FPGA

Post by Mattias » Tue Aug 29, 2023 10:40 am

:?
This command doesn't work:
my_computer: fpgautil -b ./myfile.bin
my_computer: fpgautil -b ./myfile.bin -n Full
doesn't work either

I keep getting an IO error...
In Petalinux I use exactly this command.
I don't really understand the overlay thing. I want a full one
load bitstream.
Can someone please show the full command for this?

Thank you very much

juretrn
Posts: 104
Joined: Tue Nov 16, 2021 11:38 am

Re: Issues loading .bit file on FPGA

Post by juretrn » Thu Aug 31, 2023 7:18 am

Mattias wrote:
Tue Aug 29, 2023 10:40 am
:?
This command doesn't work:
my_computer: fpgautil -b ./myfile.bin
my_computer: fpgautil -b ./myfile.bin -n Full
What do you mean that the command does not work? What exact error are you getting? Are you running on RP OS 2.0?

Mattias
Posts: 4
Joined: Sun Aug 06, 2023 7:44 pm

Re: Issues loading .bit file on FPGA

Post by Mattias » Fri Sep 01, 2023 7:10 pm

Hello,
ok here is an excerpt of the console...


Welcome to Ubuntu 22.04.1 LTS (GNU/Linux 5.15.0-xilinx armv7l)

* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage

This system has been minimized by removing packages and content that are
not required on a system that users do not log into.

To restore this content, you can run the 'unminimize' command.
##############################################################################
# Red Pitaya GNU/Linux Ecosystem
# Version: 2.00-5e06f6363
# Build: 15
# Branch:
# Commit: 5e06f6363b7b23957dbf10508ba01a966c2ab3a6
# U-Boot: "redpitaya-v2022.1"
# Linux Kernel: "branch-redpitaya-v2022.3"
# Pro Applications: ""
##############################################################################
Last login: Sun Aug 6 11:04:15 2023
root@rp-f05807:~#
root@rp-f05807:/home/runme# ls -l
total 5184
-rw-r--r-- 1 root root 20480 Mar 13 07:15 ConfigDB.dB
-rw-r--r-- 1 root root 281 Mar 8 10:20 octopus.service
-rwxr-xr-x 1 root root 1104836 Aug 6 11:55 PS_Octopus_v1.31.0
-rw-r--r-- 1 root root 422 Feb 28 2023 README.md
-rw-r--r-- 1 root root 2083740 Aug 29 08:21 red_pitaya_top.bin
-rw-r--r-- 1 root root 2083850 Aug 29 08:21 red_pitaya_top.bit
-rw-r--r-- 1 root root 300 Mar 13 08:03 Start_Octopus.sh
root@rp-f05807:/home/runme#
root@rp-f05807:/home/runme# fpgautil -b red_pitaya_top.bin <<<< 1. command <<<<<
sh: 1: echo: echo: I/O error
BIN FILE loading through FPGA manager failed
root@rp-f05807:/home/runme#
root@rp-f05807:/home/runme#
root@rp-f05807:/home/runme# fpgautil -b red_pitaya_top.bin -n Full <<<< 2. command <<<<<
sh: 1: echo: echo: I/O error
BIN FILE loading through FPGA manager failed
root@rp-f05807:/home/runme#
root@rp-f05807:/home/runme# fpgautil -b red_pitaya_top.bin -f Full <<<< 3. command <<<<<
sh: 1: echo: echo: I/O error
BIN FILE loading through FPGA manager failed
root@rp-f05807:/home/runme#
root@rp-f05807:/home/runme# fpgautil -b red_pitaya_top.bin -o /sys/class/fpga_manager/fpga0/
Error: Overlay already exists in the live tree
root@rp-f05807:/home/runme#
root@rp-f05807:/home/runme#



As always, I created the *.bit and *.bin files with vivado 2020.2.
I just want to fully load this image.

Thanks for the help
greeting
Mattias

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 3 guests