5.1.2 Dual Port RAM

Mega-Wizard
Use Altera Mega-Wizard to generate altera 3port-ram.

RTL Project
Wizard generated "sram3port_32x256.v.
Add this file to RTL project .
Add also altera_mf.v to RTL project. "altera_mf.v" is altera Mega-function library.

Notes:
In addition you need "220model.v" when you generated "lpm_mult.v" by wizard.

Fig. below show RTL simulation(rtl_sram_test.vtakprj).
qa,qb is output data of SRAM-port.

Test bench source is as below.

Synthesis by Quartus

Gate simulation
Make project for gate-simulation project in folder where *.vo file exists as below. It is not necessary to add 3port_sram_32x256.v or altera_mf.v in this project.

Fig. below shows gate level simulation.