Create A New Verilog Project in Xilinx ISE 6.2i, and Name It Ram
Create A New Verilog Project in Xilinx ISE 6.2i, and Name It Ram
2. Go
3. Select
4.ClickNext.
5. From
the select core type window, select Memories & Storage Elements->RAMs & ROMs->Single Port Block Memory 6. Click Next 7. Click Finish.
You will see the following Single Port Block Memory GUI:
8. Fill out the Component Name, Width and Depth text box accordingly. 9. Select a Port Configuration. 10. Click Next.
15. Open the CORE GENERATOR utility (Start-> All Programs > Xilinx ISE 6-> Accessories->CORE GENERATOR).
This gives you the following window:
17. Click Add Block. 18. Give your block a name (spram). 19. Click OK.
20. Fill the text box with appropriate parameters for Depth and Width. 21. Select your radix for address and data. 22. Fill out the desired data for each address. 23. Click File->Save Memory Definition.
Select the same directory as your project.
28. Check the Load Init File checkbox and select the .COE file that you generated earlier.
30. Create a new verilog source file in the project navigator with the appropriate input and output ports (for spram your input is ADDR, CLK and output is DOUT). 31. To instantiate the spram open the .veo , which was created when you generated the CORE and copy. 32. Highlight the inserted code in .veo from //----------- Begin cut here for INSTANTIATION TEMPLATE --// to // INST_TAG_END ------ End INSTANTIATION Template
33. Copy and paste this code in your top level verilog source code file.
34. Synthesis your code. 35. Now simulate your code. Note: Since you are using a CORE model sim will need the xilinxcorelib. If the libraries are not compiled follow the direction below to compile the libraries from the project GUI.
Running CompXLib from the Project Navigator GUI (6.1i or later) 1. Click the appropriate device (e.g., xcv50-6bg256) in the Sources in Project Window. 2. Right-click Compile HDL Simulation Libraries in the Processes for Source Window. 3. Select Properties.
5. Click OK. 6. Double-click Compile HDL Simulation Libraries in the Processes for Source Window.