OpenFPGA provides bash/zsh shell-based shortcuts to perform all essential functions and navigate through the directories. Go to the OpenFPGA directory and source openfpga.sh
cd ${OPENFPGA_PATH} && source openfpga.sh
Note
The OpenFPGA shortcut works with only a bash-like shell. e.g., bash/zsh/fish, etc.
Once the openfpga.sh
script is sourced, you can run any following commands directly in the terminal.
list-tasks
This command lists all the OpenFPGA tasks from the current task directory. default task directory is considered as ${OPENFPGA_PATH}/openfpga_flow/tasks
run-task <task_name> **kwarags
This command runs the specified task. The script will first look for the task in the current working directory. If it is not in the current directory, it will then search in TASK_DIRECTORY
(relative to task directory). You can also provide a path as a task_name, for example, run-task basic_tests/generate_fabric
The valid arguments listed here <_openfpga_task_args>_, you can also run `run-task run-task to get the list of command-line arguments.
create-task <task_name> <template>
It creates a template task in the current directory with the given task_name. the template is an optional argument; there are two templates currently configured - vpr_blif
: A template task for running flow with .blif file as an input (VPR + Netlist generation) - yosys_vpr
: A template task for running flow with .v file as an input (Synthesis + VPR + Netlist generation) you can also use this command to copy any example project; use a list-tasks
command to get the list of example projects for example create-task _my_task_copy basic_tests/generate_fabric
create a copy of the basic_tests/generate_fabric
task in the current directory with _my_task_copy
name.
run-modelsim
This command runs the verification using ModelSim. The test benches are generated during the OpenFPGA run. Note: users need to have VSIM
installed and configured
run-regression-local
This script runs the regression test locally using the current version of OpenFPGA. NOTE Important before making a pull request to the master
unset-openfpga
Unregisters all the shortcuts and commands from the current shell session