Modelsim Library compilation for novice headaches

Source: Internet
Author: User

It is estimated that many people buy CB Brother's book to see, they are learning Modelsim simulation process may have encountered clearly in accordance with the steps in the book to add the device library, but the following error occurred:

First of all, I would like to say that the CB Brother MODELSIM-ALTERA10.1D is installed with the quartusii together, it has compiled Altera's device library. It is a free version of the simulation tool, do not need to crack, of course, its function is not the most powerful, simulation speed is not the fastest, but has been able to meet our general simulation. Some people may have installed a faster SE version of the Modelsim without the Altera device library, which is where the problem with the device library comes in, especially the novice. In order to fix the mistake, here gives a solution, hope to be helpful to everyone.

(1) In our design, we often use the macro definition module, which is required to add the Altera device library, where the necessary compilation resource files have quartusii installation directory/eda/sim_lib under 220MODEL.V and Altera_ MF.V (described in Verilog), in addition to the PLL, so also the target device library, such as quartusii installation directory/eda/sim_lib cycloneive_atoms.v, and so on. Next, let's start compiling our designated device library. The Modelsim se 6.5g installed in the above blog post is compiled for the library, and the Altera file is first created in the Modelsim installation directory.

(2) Start the Modelsim simulation software, click "File"---> "Change Directory ...", in the Pop-up dialog Select the newly created Altera file in the Modelsim installation directory and click "OK".

(3) Click "File"---> "new"---> "Library ...", enter the name of the library: 220model to create a new library, click "OK".

(4) Click "Compile"---> "Compile ...", in the Popup dialog box, select the library as the newly created 220model, look for the quartusii installation directory/eda/sim_lib, Select 220MODEL.V, then click "Compile", "done".

(5) In the same vein, create a new library file ALTERA_MF and cycloneive_atoms under the Altera file, and then quartusii the compilation resource file under the installation directory/eda/sim_lib ALTERA_MF.V and Cycloneive_ ATOMS.V compile to the appropriate library file.

(6) Then add the library compiled above to the Modelsim.ini file. Right-click the Modelsim.ini file in the Modelsim installation directory and select "Properties" to remove the read-only.

(7) Open the Modelsim.ini file, add the following, then close the file and add the read-only attribute.

(8) After opening Modelsim, you can see the library we added.

(9) Next, take the sobel edge detection routine of CB brother as an example to simulate, see if there are any previous errors. Open the Modelsim project and click on "Compile"---> "Compile all", resulting in the following issues:

(10) According to the error, I can not find the source file because I changed the path of the Modelsim project, so I cannot find the source file. The workaround is to remove the source files from the project (not to tick delete from disk ) and reload the source files.

(11) from the new full compilation source files, found that the compilation passed.

(12) Click "Simulate"---> "Start Simulation ...", since the Shift_ram and PLL are used in this design, you need to add the search library 220model, Altera_ under the Libraries tab MF and Cycloneive_atoms.

(13) Switch to the Design tab, expand Library Work, select VIDEO_IMAGE_PROCESSOR_TB, and click "OK" to start the simulation.

(14) The results show that there is no signal, and the compiled information can be designed and optimized.

(15) The solution is to replace the "Voptflow = 1" of the Modelsim.ini file with "Voptflow = 0" ( remember to remove the Modelsim.ini attribute before modifying, and then change the read-only back ).

(16) Sometimes the following problems arise, my personal solution is to re-establish the project, I do not know whether we have a better way (want to tell each other).

(17) After rebuilding the project, the simulation is done.

I am dizzy, now it is 2:30, tomorrow morning 8:30 also to internship! It's time to sleep, 88, goodnight * ^_^ *

Modelsim Library compilation for novice headaches

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.