From 4a16220034f771a5cdf997b31707da9094fe2ed7 Mon Sep 17 00:00:00 2001 From: Erik Kooistra <kooistra@astron.nl> Date: Tue, 2 Sep 2014 07:44:52 +0000 Subject: [PATCH] Clarified and reorganized. --- tools/setup_unb.sh | 77 ++++++++++++++++++++++++++++++++++------------ 1 file changed, 58 insertions(+), 19 deletions(-) diff --git a/tools/setup_unb.sh b/tools/setup_unb.sh index c02a7903e8..94e7e7e1d7 100755 --- a/tools/setup_unb.sh +++ b/tools/setup_unb.sh @@ -25,24 +25,63 @@ if [ -z "${UNB_SH}" ]; then export UNB_SH=true echo "Setup old UniBoard environment for Modelsim and Quartus" -# Altera + ModelSim -export QUARTUS_DIR=/home/software/Altera/11.1 -export MODEL_TECH=/home/software/Mentor/modeltech -export NIOSDIR=${QUARTUS_DIR}/nios2eds -export QUARTUS_ROOTDIR_OVERRIDE=${QUARTUS_DIR}/quartus -export QUARTUS_ROOTDIR=${QUARTUS_DIR}/quartus -export MODELSIM=${UNB}/Firmware/sim/modelsim/modelsim.ini -export MODEL_TECH_ALTERA_LIB=/home/software/modelsim_altera_libs/11.1 -export SOPC_KIT_NIOS2=${NIOSDIR} - -PATH=$PATH:\ -${NIOSDIR}/bin:\ -${NIOSDIR}/sdk2/bin:\ -${NIOSDIR}/bin/gnu/H-i686-pc-linux-gnu/bin:\ -${QUARTUS_ROOTDIR}/bin:\ -${QUARTUS_ROOTDIR}/sopc_builder/bin:\ -${MODEL_TECH}/linux_x86_64 - -export PATH +# 1) Usage + +# Source this script after the setup_radiohdl.sh in the .bashrc to setup the old UniBoard environment for Modelsim and Quartus. + + +# 2) Default tool settings + +# The $RADIOHDL environment variable is defined by first calling setup_radiohdl.sh in the .bashrc. + +. ${RADIOHDL}/tools/quartus/quartus_version.sh 11.1 +. ${RADIOHDL}/tools/quartus/quartus_generic.sh +. ${RADIOHDL}/tools/modelsim/modelsim_version.sh 6.6c + + +# 3) Synthesis + +# For Quartus synthesis in the old UniBoard environment no further settings are needed. + + +# 4) Simulation + +# For Modelsim simulation in the old UniBoard environment the following setings are needed: + +# The old UniBoard environment uses a libraries.ini that gets set in a project specific modelsim.ini. The default modelsim.ini +# gets overrulled via the MODELSIM environment variable. For RadioHDL the default modelsim.ini as it comes with the tool is +# used, because that is fine. This implies that a libraries.ini can not be invoked via the modelsim.ini. Therefore instead of +# using a central libraries.ini for RadioHDL all libraries get mapped directly in the generated modelsim project files. + +# The $UNB environment variable is already defined in the setup_radiohdl.sh in the .bashrc. + +# To simulate the old UniBoard $UNB environment do: +# +# > unb_msim & +# + +# The old UniBoard envrionment uses dedicated libraries.ini and commands.do for some application projects. These projects can +# be simulated by starting Modelsim with: +# +# > paasar_msim & +# > aartfaac_msim & +# +# In addation to the 'lp' and 'mk' commands for the UNB libraries these projects have 'lpa' and 'mka' commands to load and make +# the application specific libraries for simulation. + +export AARTFAAC=${SVN}/UniBoard_FP7/Aartfaac/trunk +export PAASAR=${SVN}/UniBoard_FP7/Paasar/trunk + +export PATH=${PATH}:\ +${AARTFAAC}/Firmware/sim/modelsim:\ +${PAASAR}/Firmware/sim/modelsim + +# When Modelsim is started using the unb_msim script the setup sofar is sufficient. + +# The alias unb_sim='vsim -do ${UNB}/Firmware/sim/modelsim/commands.do' is no longer supported, because the unb_msim script is +# equivalent in usage and easier to maintain because the start script contains the required settings. Or add to the .bashrc: +# +# alias unb_sim=unb_msim +# fi -- GitLab