1. Getting Started

1.1. Installation

Option A - Standalone Install

This option should be used for a standalone installation, when OpenFPGA is not installed. These following commands will checkout the latest version of the OpenFPGA-Softcores platform and its submodules (OpenFPGA, PicoRV32, Ibex, VexRiscv, …), install OpenFPGA framework and source the project environment.

git clone --recursive https://github.com/lnis-uofu/OpenFPGA-Softcores.git
cd OpenFPGA-Softcores
third_party/install_openfpga.sh                  # install OpenFPGA framework
source setup_env.sh                              # source the project environment

Note

To install OpenFPGA make you have the following dependencies installed, as requested here: OpenFPGA - How to Compile

Dependencies

To install all Python packages required by both OpenFPGA framework and OpenFPGA-Softcores project, execute the following commands either on your own machine or in a virtual Python environment.

pip install -r requirements.txt                  # to support OpenFPGA-Softcores scripts
pip install -r $OPENFPGA_PATH/requirements.txt   # to support OpenFPGA scripts
pip install -r docs/requirements.txt             # only for developers

Note

Currently Python 3.6 is supported.

1.2. Virtual Python Environment

If you are in a restricted environment without admin rights, you can install a virtual Python environment. Execute the following commands to add the pyvenv directory in the root of the project, then execute the list of commands described in the previous Dependencies section.

python3 -m venv pyvenv                                 # create a virtual env
source pyvenv/bin/activate                             # active virtual env (bash/zsh)
pip install --upgrade pip                              # upgrade Pip

If you have admin rights, you can still install a virtual Python environment according to operating system. This is currently working on Linux/MacOS operating systems.

Ubuntu (>=18.04)

Open up a terminal and enter the following command sequence.

python3 --version                                      # check for Python >3.6
sudo apt update                                        # update package information
sudo apt install python3-dev python3-pip python3-venv  # install dependencies
python3 -m venv pyvenv                                 # create a virtual env
source pyvenv/bin/activate                             # active virtual env (bash/zsh)
pip install --upgrade pip                              # upgrade Pip

macOS (>=10.15)

Open up a terminal and enter the following command sequence.

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
export PATH="/usr/local/opt/python/libexec/bin:$PATH"
brew update
brew install python
python3 --version                                      # check for Python 3.6 - 3.10
python3 -m venv pyvenv                                 # create a virtual env
source pyvenv/bin/activate                             # active virtual env
pip install --upgrade pip                              # upgrade Pip

Warning

Currently, the OpenFPGA framework is only supported for the Ubuntu >=18.04 and Red Hat >=7.5 platforms.