beautypg.com

Altera Avalon Verification IP Suite User Manual

Page 171

background image

2–4

Chapter 2: Qsys Tutorial

Verifying Avalon-ST DUT

Avalon Verification IP Suite User Guide

May 2011

Altera Corporation

2. Click Generate. Save the system if you are prompted to do so.

3. To view information about the generated testbench file, open

st_bfm_qsys_tutorial_tb.html

located in the following directory:

\ug_avalon_verification\qsys\st_bfm_qsys_tutorial\
testbench

.

4. In the st_bfm_qsys_tutorial_tb.html file, verify that the names of the generated

BFMs match the instance names in

Table 2–4

.

5. Use the instance names listed in

Table 2–4

to define and access the APIs of the

corresponding BFMs in your test program.

Figure 2–2

shows a code example for

using the instance names to define a particular BFM in the test program.

1

The test program for this tutorial is located in
\ug_avalon_verification\qsys\user_test_program.

Output Directory

Path

\ug_avalon_verification\qsys\st_

bfm_qsys_tutorial

Table 2–4. Generated BFM Instance Names

BFM Type

Instance Name

altera_avalon_clock_source

st_bfm_qsys_tutorial_inst_clk_bfm

altera_avalon_reset_source

st_bfm_qsys_tutorial_inst_reset_bfm

altera_avalon_st_source_bfm

st_bfm_qsys_tutorial_inst_st_in_bfm

altera_avalon_st_sink_bfm

st_bfm_qsys_tutorial_inst_st_out_bfm

Figure 2–2. Using Instance Names to Define BFMs

Table 2–3. Generation Tab Parameter Values

Parameters

Value