Featured post

Top 5 books to refer for a VHDL beginner

VHDL (VHSIC-HDL, Very High-Speed Integrated Circuit Hardware Description Language) is a hardware description language used in electronic des...

Friday 23 December 2011

Compiling Xilinx library for ModelSim simulator

It was all running cool with VHDL but when i tried to do post Place and Route simulation using SDF file of my design i stuck with following errors:

# ** Error: (vsim-SDF-3250) mips_struct.sdf(18): Failed to find INSTANCE '/top/dut/U1262'.
# ** Error: (vsim-SDF-3250) mips_struct.sdf(19): Failed to find INSTANCE '/top/dut/U1262'.
# ** Error: (vsim-SDF-3250) mips_struct.sdf(20): Failed to find INSTANCE '/top/dut/U1262'.
# ** Error: (vsim-SDF-3250) mips_struct.sdf(21): Failed to find INSTANCE '/top/dut/U1261'.
# ** Error: (vsim-SDF-3250) mips_struct.sdf(22): Failed to find INSTANCE '/top/dut/U1261'

googling a lot i found that i need to compile xilinx libraries and had to map it with ModelSim to get it worked. For this u need to write CompXlib in your TCL window of Xilinx.

CompXLib uses the ModelSim "vmap" command for library mapping. If the ModelSim environment variable is set, then the ".ini" file pointed to by the environment variable is modified. If the variable is not set, a local (in the directory in which CompXLib is run) "modelsim.ini" file contains the library mappings from the "vmap" command issued by CompXLib. If the "modelsim.ini" file is not writeable, the "vmap" command will make a local copy of the "modelsim.ini" file and write the library mappings to this file.

I used the “compxlib” command but still it was not working for me. When i checked my modelsim.ini file I found that the libraries was not mapped so i write below command in the modelsim.ini file and finally i find all compiled xilinx libraries in my library window of modelsim.

UNISIMS_VER = C:\Xilinx\10.1\ISE\verilog\mti_se\unisims_ver
UNIMACRO_VER = C:\Xilinx\10.1\ISE\verilog\mti_se\unimacro_ver
UNI9000_VER = C:\Xilinx\10.1\ISE\verilog\mti_se\uni9000_ver
SIMPRIMS_VER = C:\Xilinx\10.1\ISE\verilog\mti_se\simprims_ver
XILINXCORELIB_VER = C:\Xilinx\10.1\ISE\verilog\mti_se\XilinxCoreLib_ver
SECUREIP = C:\Xilinx\10.1\ISE\vhdl\mti_se\secureip
AIM_VER = C:\Xilinx\10.1\ISE\verilog\mti_se\abel_ver\aim_ver
CPLD_VER = C:\Xilinx\10.1\ISE\verilog\mti_se\cpld_ver
UNISIM = C:\Xilinx\10.1\ISE\vhdl\mti_se\unisim
UNIMACRO = C:\Xilinx\10.1\ISE\vhdl\mti_se\unimacro
SIMPRIM = C:\Xilinx\10.1\ISE\vhdl\mti_se\simprim
XILINXCORELIB = C:\Xilinx\10.1\ISE\vhdl\mti_se\XilinxCoreLib
AIM = C:\Xilinx\10.1\ISE\vhdl\mti_se\abel\aim
PLS = C:\Xilinx\10.1\ISE\vhdl\mti_se\abel\pls
CPLD = C:\Xilinx\10.1\ISE\vhdl\mti_se\cpld

** C:\Xilinx\10.1 is path in my system. Please check paths and make changes accordingly.

alternatively you can also use following commands

compxlib -s mti_se -arch virtex -lib unisim -lib simprim -lib xilinxcorelib -l vhdl -dir C:\Mentor\libraries\xilinx\10.1\ISE_Lib\ -log compxlib.log -w
compxlib -s mti_se -arch virtex2p -lib unisim -lib simprim -lib xilinxcorelib -l vhdl -dir C:\Mentor\libraries\xilinx\10.1\ISE_Lib\ -log compxlib.log -w
compxlib -s mti_se -arch virtex4 -lib unisim -lib simprim -lib xilinxcorelib -l vhdl -dir C:\Mentor\libraries\xilinx\10.1\ISE_Lib\ -log compxlib.log -w
compxlib -s mti_se -arch spartan3 -lib unisim -lib simprim -lib xilinxcorelib -l vhdl -dir C:\Mentor\libraries\xilinx\10.1\ISE_Lib\ -log compxlib.log -w
compxlib -s mti_se -arch virtex5 -lib unisim -lib simprim -lib xilinxcorelib -l vhdl -dir C:\Mentor\libraries\xilinx\10.1\ISE_Lib\ -log compxlib.log –w

**(C:\Mentor\libraries\xilinx\10.1\ISE_Lib\  is my path, you can use your own)

No comments:

Post a Comment

Please provide valuable comments and suggestions for our motivation. Feel free to write down any query if you have regarding this post.