tcl, modelsim and vhdl generics

R

Riyaz

Hi there,

Is there a way of updating vhdl generic values in a testbench at successive
iterations of a Tcl script? I have a testbench with the entity having a
generic declaration. I wish to run the same testbench multiple times with a
different value for the generic each time. I am using modelsim and
executing a Tcl macro to run the testbench.

Kind regards
 
J

Jonathan Bromley

Hi there,

Is there a way of updating vhdl generic values in a testbench at successive
iterations of a Tcl script? I have a testbench with the entity having a
generic declaration. I wish to run the same testbench multiple times with a
different value for the generic each time. I am using modelsim and
executing a Tcl macro to run the testbench.

Read the docs on the [vsim] command, particularly the -g and -G
options which allow you to patch generics from the command line.

It's also possible, and perhaps rather more fun, to parameterise
the design using deferred constants in a package. These deferred
constants can then be initialised from a file, or - even more fun -
from data piped from a Tcl script to the simulator's stdin channel.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top