Sei sulla pagina 1di 7

User’s Guide for Mentor Graphics’ ADvance MS tool

Alain Vachoux
EPFL-LSM
alain.vachoux@epfl.ch

The ADvance MS tool from Mentor Graphics offers a simulation environment for VHDL-AMS
models. This document presents the main commands available in the tool as well as some speci-
fic issues regarding the partial coverage of the IEEE 1076.1-1999 standard.

Setting up the user’s environment

The .cshrc file must include the following lines:

source /softs/site/pre_cshrc
-------- start user specific section here
# set EDA tools
set mentor_adms = 2004.3
-------- end user specific section here
source /softs/site/post_cshrc

VHDL-AMS source code edition

Use any text editor. The predefined alias edt calls the nedit text editor. Use the extension .vhd for
the source files.
It is recommended to use one file per entity/architecture pair or package header/body pairs. If
more than one architecture i sdefined for the same entity, it is better to use different files for the
entity and the architectures.

Library management

The library WORK must exist before any compilation. The library is created (once) in your wor-
king directory with the valib command:

valib lib-name
valib mylib -- create the directory ‘mylib’ in the current directory

Once the library directory is created, the logical name WORK is bound to it and a local adms.ini
file registers the mapping.
The vasetlib command allows for associating an existing library directory to the logical WORK
library. This is required when the current association must be modified:

vasetlib mylib

The vamap command allows for associating any logical library to an existing library directory:

vamap logical-name directory-name


vamap work ./mylib -- map the logical name WORK to the mylib directory

Alain Vachoux 16/5/05 1/7


User’s Guide for Mentor Graphics’ ADvance MS tool

vamap -- lists all current library mappings


vamap mylib -- list library mapping for mylib

vamap -del directory-name -- remove the mapping for the given directory name

The vadir command allows for displaying the content of a library:

vadir -- lists content of library WORK (only entities)


vadir -r -- same but with all related architectures as well
vadir -l -- lists timestamps
vadir -lib mylib -- lists content of library mylib

The vadel command allows for removing a design unit from a library:

vadel opamp -- remove all design units of unit opamp in library WORK
vadel opamp bhv1 -- only remove architecture bhv1
vadel -lib mylib opamp -- remove in specified library
vadel -lib mylib opamp bhv2 -- idem

Compilation

The vacom command allows for compiling a VHDL-AMS source:

vacom opamp_bhv.vhd -- compile in library WORK


vacom -work bibliothèque opamp_bhv.vhd -- compile in specified library

Simulation

The vasim command starts the simulation:

vasim [ option(s) ] [ entity [ architecture ] ]

Options:

-lib library-name -- use the specified library instead of WORK


-cmd command-file

Example:

vasim -cmd opamp.cmd opamp


-- simulates the last compiled architecture of opamp with the commands in opamp.cmd

The command file is a text file (with .cmd extension) and is required when the model to simulate
is analog or mixed. It includes the simulation commands. For example:

The first line is always interpreted as a title and is therefore ignored in simualtion!
.tran 1ms 100ms
.option eps=1.0e-5

The .tran command asks to run a time-domain simulation from time 0 to time 100 ms. Results
will be tabulated in 1 ms increments. The .option command defines the value of the eps tol-
erance that controls the numerical simulation algorithms.

Alain Vachoux 16/5/05 2/7


User’s Guide for Mentor Graphics’ ADvance MS tool

The vasim command without parameters starts the graphical interface of the simulation environ-
ment. In that case, a dialog window “Load Design” appears to invite you to enter the design entity
to simulate and the command file to use.

WORK library

compiled design units

command files

It is possible to create a command file at that time by cloicking on the New button. It is possible
to modify an existing command file by clicking on the Edit button:

The dialog window offers the possibility to specify a limited number of simulation parameters,
namely the simulation type (OP, AC or transient) and its related parameters. Clicking on the Save
button saves the values in the command file.

Alain Vachoux 16/5/05 3/7


User’s Guide for Mentor Graphics’ ADvance MS tool

The More button alllows for specifiying additional simulation parameters:

The numerical integration method may be changed if the time-domain simulation has accuracy
or convergence problems. It is also sometimes required to change the value of the Hmax parame-
ter (the maximum integration timestep) to guarantee smooth waveforms (e.g. sine waveforms).
This specification is equivalent to the step limit specification of VHDL-AMS.

Alain Vachoux 16/5/05 4/7


User’s Guide for Mentor Graphics’ ADvance MS tool

The Load button loads the specified design entity and its related command file for simulation.
The simulator console then displays the loaded design units:

The important icons in the console are:


Load Design ( ), Restart ( ), Run ( ) the number of specified fs, and
Run All ( ).
It is possible to display all the views of the model with the View menu:
• The model structure (all its related files and design units)

• The model nets (signals, quantities, terminals) and the model variables

Alain Vachoux 16/5/05 5/7


User’s Guide for Mentor Graphics’ ADvance MS tool

• The VHDL-AMS source

The waveforms to display are selected in the Nets vue as follows:

It is possible to select specific signals, terminals or quantities in the model hierarchy by selecting
the proper context in the Structure vue.
The waveforms will appear in the EZwave window as soon as the simulation has started.
The Run All command ( ) starts the simulation and stops after the maximum simulation time
or frequency is reached.

Alain Vachoux 16/5/05 6/7


User’s Guide for Mentor Graphics’ ADvance MS tool

The EZwave window has its own commands for manipulating the waveforms:

Documentation

The adms_doc and anacad_doc aliases start acroread with the available online PDF documen-
tation.

Support of IEEE standard 1076.1-1999

The ADvance MS tools does not yet supports the full standard 1076.1 language definition. You
can read the annex C of the "ADvance MS User’s Manual" document for more details (available
with the adms_doc alias.
The energy domain packages are available in the IEEE_PROPOSED library:

library ieee_proposed;
use ieee_proposed.electrical_systems.all;

Alain Vachoux 16/5/05 7/7

Potrebbero piacerti anche