Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to fill (initialize) large ROM memories?

Status
Not open for further replies.

riiete

Programmer
May 7, 2004
2
FI
Hi!

How can I fill large ROM memories in VHDL? Writing all values by hand seems quite a robust if large memory has to be intialized:

constant ROM: rom_array := (
"001010", "011010", "010111",
...
... --thousands of numbers
);

For example if values of a sin fuction needs to be initialized into a ROM, can I use some loop structure to calculate and initialize the values? Few tries has produced nothing but errors..

-Riika-
 
Write a function that returns the same type as your constant
(rom_array). Then initialise your constant with a call to the function.

The function will then have your algorithm to create your table.

--
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top