Performing Functional Simulation of the system created with Qsys in Riviera-PRO


This document describes the steps required to run functional simulation of Altera Qsys design in Riviera-PRO. The Qsys tutorial design example is used to demonstrate the flow.

Requirements and Limitations

This application note assumes the following:

  1. You have the following software installed and licensed:

    • Altera Quartus® II version 14.1 or later, and all necessary devices from Altera

    • Riviera-PRO 2015.02 or later

  2. You have downloaded the Qsys tutorial design example ( used in this application note. You can download it from the Qsys Tutorial Design Example web page.

  3. You have followed the instructions provided in chapter 5 of the Qsys System Design Tutorial and have generated the rivierapro_setup.tcl script.

Running the QSYS Design Simulation

  1. Once you generate the simulation models in Qsys, the rivierapro_setup.tcl script is generated in the tt_qsys_design/simulation_tutorial/ pattern_generator/testbench/ pattern_generator_tb/simulation/aldec folder.

    Figure 1. rivierapro_setup.tcl script

  2. Open Riviera-PRO. Change the location to point to the rivierapro_setup.tcl script. Execute the following command from the Console:

    cd <path to the design>/tt_qsys_design/simulation_tutorial/pattern_generator/testbench/pattern_generator_tb/simulation/aldec

    where <path to the design> points to the folder where you extracted the tt_qsys_design_zip archive. Alternatively, you may also navigate using the Filesystem window.

    Figure 2. File system window in Riviera-PRO

  3. Open the rivierapro_setup.tcl script. This script sets up all necessary environment variables, compiles Altera libraries, compiles design files, and initializes the simulation. The script can be executed as is, or you can modify any of the commands in it according to your needs.

    Table 1, shown below, provides the description of the alias commands used in the script. The commands described below are the alias commands that are defined in the rivierapro_setup.tcl script:

    Table 1- Command aliases


    for compilation device library files


    for compilation the design files


    for elaboration top level design (top level design is defined in script by TOP_LEVEL_NAME variable)


    for elaboration the top level design with optimization disabled (with -dbg -o2 options)


    for compilation all the design files and elaboration the top level design


    for compilation all the design files and elaboration the top level design with optimization disabled with -dbg -o2 options)

  4. Modify line 33 as follows and save the script:

    set QSYS_SIMDIR "../../.."
  5. Execute the script. Right-click the script in the Filesystem window and select Execute from the drop-down menu.

    Figure 3. Executing a script in Riviera-PRO

  6. Execute the dev_com command from the Console. This will compile the following libraries:

    • altera_ver

    • lpm_ver

    • sgate_ver

    • altera_mf_ver

    • altera_lnsim_ver

    • cycloneiii_ver

  7. Execute the com command from the Console. This will compile design source files

  8. Execute the elab command from the Console. This will initialize the simulation.

  9. Run the simulation by executing the run 40us command from the Console.


Altera Qsys designs can be successfully simulated in Riviera-PRO. To get detailed information about creating a system with Altera Qsys, refer to the following link:

If you have difficulty simulating the Qsys design in Riviera-PRO, please contact Aldec Support via customer portal

Ask Us a Question

Ask Us a Question

Captcha ImageReload Captcha
Incorrect data entered.
Thank you! Your question has been submitted. Please allow 1-3 business days for someone to respond to your question.
Internal error occurred. Your question was not submitted. Please contact us using Feedback form.