Tutorial:Vista Model Builder Tutorial

From NCSU EDA Wiki
Jump to: navigation, search


We will use Vista and Model Builder to design a shared bus SoC. Model Builder is a TLM-2.0 based model generator, providing tools and a programming environment for model generation and management. Models created in Model Builder can be used in any SystemC design. Vista is a native, source-based, SystemC ESL (Electronic System Level) design and verification platform that incorporates advanced coding facilities, browsers, and a verification tool-set targeted for high level and transaction-level modeling.

In this tutorial you will (1) make models using Model Builder and modify them (2) make a project in Vista (3) build the design using the generated models (4) Simulate the design using Vista and (5) analyze the simulation results. The design includes CPU, AHB bus, memory and a DMA.


A Tutorial.pdf file comes along with these tools and we will use this tutorial as it shows how to design a simple SoC. Here is the address where you can find the tutorial:


Also, we have provided the text files that include the additional codes you need to add to the created models by Model Builder to modify them. Also you can find the main.cc and top_pvt.hpp and parameters.txt which are used to build the design in Vista.

Start Vista and Model Builder Framework

- Create a folder like "vista_tutorial" to start the tutorial

- Create the "models" folder in the folder that you just created. We will usethis folder to save the components created by Model Builder

% add mg_vista
% vista -sc22 &

- To run the model Builder, follow Tools->ModelBuilder in Vista environment.


To make the tutorial easier to follow, and generate outputs similar to the ones reported in the Tutorial.pdf we have provided a few auxiliary comments on the tutorial slides:

- Skip slide #18

- On slide #29, remove “printParameters();” from CPU_pv.cpp in the constructor section

- On slide #35 use Tools->Create new model... instead of File->New->Model...

- On slide #46 create PVT model instead of PV

- On slide #56 use Tools->Create new model... instead of File->New->Model...

- On slide #63 remove '#ifdef MB_DEBUG' and '#endif' scripts from the slave_callback_read and slave_callback_write functions.

- We have added scripts to the debug functions (in MEMORY_pv.cpp) in slide #63 to have outputs similar to the ones at the end of tutorial

- On slide #75 make a new project by Project->New Project... and save the project; you can leave the name unchanged

- On slide #79 on left, make a change and deactivate "stop after elaboration" in General -> Debugging

- On slide #79 on right use the following text in the Trace Script window:

trace_transactions -name traced_* -tree
trace -kind sc_object_attribute -name *_power -tree

More About Vista and Model Builder

Regarding further reading about these tools, you will find the following documents useful: