Simulating with Model. Sim (6. 1. 11 labkit)6. Comfortable with for writing and revising your code. Functional Simulation of VHDL or Verilog. Pre -Synthesis Simulation for VHDL Code in Modelsim. Simulate ->Simulate and by accessing the simulation. ModelSim Tutorial Getting. Now it's time to simulate your design. ModelSim simulator is invoked with. Compile VHDL source code into a specified design. Is project will give you a basic understanding of ModelSim and the Verilog. Simulating in ModelSim. This document describes how to setup and run Verilog simulations, using Project Navigator and Model. Sim. Simulations are controlled using testbenches. A testbench is an additional Verilog module (not part of the actual system design) used to generate the appropriate waveforms on the input ports of the module under test, in order to exercise the functionality of that module. Optionally, the testbench also monitors the outputs of the module under test, and generates warnings if they deviate from the expected output values. To setup the project for this tutorial, launch Project Navigator and create a new project (targeting the labkit's XC2. V6. 00. 0- 4. BF9. FPGA). Make sure Model. Create VHDL Model & Run ModelSim . Getting Started with Quartus II Simulation Using the ModelSim-Altera Software. Getting Started with Quartus II Simulation Using the ModelSim. Sim- SE Verilog is selected as simulator in the project properties form. Add the following source files to the project: fsm. However, if you wish, Project Navigator can automatically generate a skeletal testbench for any module in your design. The skeletal testbench includes code to instantiate the module under test, and to initialize the input signals to the module. You must extend the testbench in order to generate the stimulus waveforms necessary to test your module. Select the fsm module in the project source tree. Right- click in the source- tree area and choose . ISE will generate a basic testbench which instantiates the fsm module (the unit- under- test, or UUT) and declares wire and reg signals for all of its ports. The testbench will also include the an initial block, which initializes all of the inputs to the UUT. You can extend this block to generate whatever stimulus you wish to apply to the UUT. Now that you know how to create your own testbenches, download the finished testbench for the fsm module here: fsm. This testbench includes code to generate the reset, clock, and go signals. It also checks the state outputs, and will print error messages to the Model. Sim console, if the fsm module does not function as intended. If you auto- generated a testbench, as described above, delete it from the project now. Choose Simulation Only for verilog file type. Project Navigator will identify that fsm. You must first select . To use this interface, Model. Sim must be selected as the default simulator for the current project. Since there are only a limited number of Model. Sim licenses available for the class, please try to avoid running multiple copies of Model. Sim at the same time.)Behavioral Simulation. A behavioral simulation uses the Verilog source code you wrote in order to model the behavior of the module under test. Neither gate delays nor interconnect delays are modeled. Furthermore, functionality of the behavioral model may not match that of the synthesized logic, if you make use of Verilog language features that the synthesis engine cannot handle. There is little point in running more realistic simulations until the behavioral model works correctly. Behavioral simulation results for the example FSMNon- Behavioral Simulations Non- behavioral simulations are performed on some form of synthesized netlist. The functionality of the gates is modeled using a generic Xilinx library, but propagation delay is not modeled. The simulation should match the behavior of the actual hardware, but will assume the hardware is infinitely fast. This library includes accurate gate delay information. However, interconnect delay is not modeled, because the design at this stage has not yet been placed and routed. Post- Mapping simulation results. Note the clock- to- state propagation delay of 1. Post- Place- and- Route Simulation. A post- place- and- route simulation models interconnect delay, as well as gate delay. This type of simulation will most accurately match the behavior of the actual hardware. However, for large designs, it can take a significant amount of time to extract the interconnect delay values from the place- and- route information, and a significant amount of time to run the actual simulation. It really only makes sense to perform post- place- and- route simulations at the top level of a design. If you perform a post- place- and- route simulation on a submodule, the place- and- route process is rerun, using the submodule as the top- level of the design. The interconnect delays for the submodule simulation will therefor not match the interconnect delays for that submodule when it is laid out as part of the complete project. Post- Place- and- Route simulation results. The total clock- to- state propagation delay is about 4ns. Solutions to Common Problems. The Model. Sim simulation tasks are not visible in the process window. Model. Sim is not selected as the default simulator for the current project. Make sure Model. Sim- SE is selected under.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
December 2016
Categories |