About Building the Libero Project from Gateware

Hello everyone! I hope you are great!

I am facing an issue when trying to generate the libero project with the python tools scripts. When I do
sudo python3 build-bitstream.py custom-fpga-design/my_custom_fpga_design.yaml I get the following error:

Libero not found in path

I have been trying to modify the scripts to match the path but it has not been sucessful.

Can someone recommend me how to modify the path? The thing is I am running an Ubuntu 22.04 docker and I don’t have Libero installed on Linux, but I have Libero installed on Windows.

Or if anyone who has succedded in bulding the project that can share it here, would be very appreciated.

Best Regards

Adrian

From when you install it, the PATH needs to be set. There is also a portion when you install Libero where someone can set the PATH to something different but then you need to change the PATH where things are located.

Seth

P.S. I built a project but I have not come back to it in some time. From what I remember, I was using Linux. I am sorry about not knowing how to install on Windows.

1 Like

Thank you man! Your answer is really appreciated! I installed Libero on Windows because when trying to install Libero in Ubuntu docker, a license error ocurrs due to the change of MAC address of the Ubuntu Docker everytime the computer is restarted. And I don’t have any partition disk for native Ubuntu…

Cheers dude!

1 Like

I read over the first post again…

I do not know how to manage aliases for IP in docker nor can I do that keeping the same IP or MAC in hypervisor programs.

I am sorry.

If you can find a way to install a known working Ubuntu Distro, the set up is as easy as it is stated.

a. Sign up for the one year Silver Version for Ubuntu (Linux)

  1. Download Libero
  2. Install
  3. Make your dir. and route what is available on the Gateware files to understand the dir. PATH

b. Or…try the .py file for bitstreaming the building

  1. There is a person online on this forums
  2. He put forth effort to make it understandable
  3. If you research his youtube channel or this forum for it, I am sure you can locate it

c. Try Windows and be the first I have heard of currently to make it work.

  1. I will keep checking back
  2. Who knows if others have made it work with Windows
  3. Good luck with Windows versioning on this forums

I think most people use both but Linux is preferred.

Also, let me research the link for the Gateware bitstream that can be used instead of Libero installs and versioning. Oh! There is also a source script to help with the install…

Let me check on that too. If you get similar Windows installs like is necessary for the Ubuntu Linux installs, one could inevitably make it work. The script handles some of the steps that are needed to push the License corrections.

Seth

P.S. Brb…

1 Like

@AdrianHerCoss ,

It seems the docs. just got updated!

https://docs.beagleboard.io/latest/boards/beaglev/fire/demos-and-tutorials/gateware/upgrade-gateware.html

In the docs. for beaglev-fire when updating and upgrading to a known, new gateware, try to make sure you (when you get to that point) add the prefix . to . ./change-gateware.sh default like stated.

I accidentally forgot to add the period prefix and borked the board…

It boots into the Cockpit but not ssh any longer. Aw!

Seth

P.S. I almost forgot the script needed for helping one along with the Gateware: https://openbeagle.org/beaglev-fire/Microchip-FPGA-Tools-Setup . I found that script a while back and it should help when building… From what I have seen and used on Ubuntu only here, it worked/works.

Thank you man! I am really considering to change natively to Ubuntu in order to make this work and not having the issue of crossed-operating system problems.

Yes! They were updated! Also this change-gateeware.sh default works for me!

What I am looking to do is to implement a SpaceWire IP Core on BeagleV-fire, I have both algorythms in .vhdl and .v but i am trying to understand how is the process of including those files to the libero project or to the server tool for FPGA fabric. :smiley:

Once again, I really appreciate your help! You are very nice and very kind to answer my topic! I wish everyone was like you in terms of helping others! From the bottom of my heart, thank you man! LEt’s keep doing some PolarFire stuff together!

Hey,

@AdrianHerCoss , I found some other stuff available from Low-latency I/O RISC-V CPU core in FPGA fabric - #21 by jkridner

Seth

P.S. There is a youtube video on that link. It shows the verilog process in the bitstream (I think). Enjoy.

1 Like

Thank you man! I will go through it! REally appreciate your help!

Best way to go, and do it natively. Your blood pressure will drop due to the lack of frustration. Also, Debian is my preferred, however some packages are only available on Ubuntu.

3 Likes

KDE Neon for me just because I prefer Plasma to Gnome. Been using Linux as my development OS now for getting on 24 years. I do have Windows in a VM for the very few times I need it and have on occasions had to use a Mac, both of which feel really bad after Linux because that is what I am used to now.

3 Likes

Thank you man! I will do it then… thank you for your answer!

1 Like

I will change to Linux natively then… thank you for your answer!

I took your advice and installed Ubuntu Desktop 22.04 natively and maaaaan, what a difference between this and docker. It is my favorite OS right now. Thank you all for the recommendation.

Just to continue with the topic! After 10 days of agony, madness and blood tears I finally made it work! (The Gateware project in Libero with the build-bitstream.py file)

1. First, I recommend to follow the Microchip Tools Setup Instructions…

https://docs.beagleboard.org/latest/boards/beaglev/fire/demos-and-tutorials/mchp-fpga-tools-installation-guide.html

And paste all export commands EXACTLY as it is in .bashrc ! Don’t change anything or you will get a lot of errors (even if you change $USER in paths you will get some errors)

2. Second, CHANGE FOLDER PERMISSION AND OWNERSHIP TO $USER.

What does this mean? This means, you should make the folder where you clone your Gateware project “FREE OF SUDO COMMAND”. You can do this with the following command

sudo chown -R $USER /home/$USER/name_of_folder

why you should do this? Because if you don’t do this and run the command python3 build-bitstream.py , you will get errors and errors due to the Logger.py file and the log functions of python.

I will tell you where was my frustration, I TRIED ALWAYS typing " sudo python3 build-bitstream.py ./custom_fpga_desing/my_custom_fpga_design.yaml and NEVER, BUT NEVER the script build-bitstreams.py gave me any idea that SUDO was actually doing the process but not recognizing the variable paths from the setup-microchip-tools.sh SO I WAS ALWAYS FIGHTING AGAINST “Libero not found” , “pfsoc_mss not found” and “bla bla bla not found”.

I hope BeagleV-Fire developers can actually give this info in the main webpage. Would save tons of days of effort and would avoid to go through all python scripts (even the make scripts from the microchip build bitstream tools).

3. Third. DO NOT USE LIBERO 2024. Keep it with v2023.2. This will cause errors as well.

4. Fourth. Install Device Tree Compiler.

sudo apt update
sudo apt install snapd
sudo snap install device-tree-compiler

To get the device-tree-compiler needed for the bitstream of the project.

5. Fifth. CHECK and DOUBLECHECK the path of the License Daemons of the License.dat file

If you don’t do this you will get errors in Synthesys (Synopsys).

Have a good time and enjoy programming this beautiful stuff. It will be frustrating sometimes but man, how good it feels to succeed in programming tasks.

If you have questions or need any assistance, surely I can help you out!

Adrian

1 Like

On April 5, Gateware was updated to allow using Libero 2024. If you fetch the latest version, it should work. (It does on Windows anyhow).

Thank you for the info, I think I fetched the Gateware before this change. So I will give it a try again then.

  1. Sixth. Use the License Daemons that come with Libero instead of trying to find and download something separately!