FPGA Intellectual Property
PCI Express*, Networking and Connectivity, Memory Interfaces, DSP IP, and Video IP
6370 Discussions

Modelsim functional simulation of DDR2 HP controller

Altera_Forum
Honored Contributor II
1,212 Views

Hello, 

 

I wanted to set up a functional simulation of DDR2 high performance controller to evaluate some design features. But the verilog part of the core uses defparam statements for generic parameters in many places, that are unsupported by Modelsim. With previous verilog or mixed language simulations (e. g. of PFL Megafunction), I replaced the defparam statements with legacy# parameter syntax. But with DDR2 controller, there is a lot of parameters particularly in megawizard generated files, that have to be regenerated for each possible design update. 

 

Do you know an alternative solution, perhaps a script to translate defparam statements for Modelsim? Or did I overlook something obvious? 

 

Best regards, 

 

Frank
0 Kudos
1 Reply
Altera_Forum
Honored Contributor II
520 Views

Hello, 

 

I found, that the problem was due to Modelsim VHDL and Verilog libraries using the same directory below fpgalibs. With VHDL version compiled last, the simulation fails. You have to recompile the Verilog version of altera_mf and lpm first. This is not obvious, cause Modelsim generally can include VHDL modules and libraries (with mixed language option license) but can't use generics with defparam (why ever). 

 

Instantiating Verilog modules with defparam always works. For this reason, Altera generally uses old style# parameter syntax in Verilog VHDL-wrapper modules. 

 

Verilog experts probably would have known... 

 

Regards, 

 

Frank
0 Kudos
Reply