Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
15 years ago

[VHDL]How to read data stocked in 1 ROM (created with Quartus)

Hello,

I work at a little program with VHDL. In my program, i created a ROM with Quartus "MegaWizard Plug-in Manager" and which is already filled with a .mif file. And then in my VHDL program, I'd like to have access to this data and use them for my calculation.

My component :

component rom_qpsk

PORT

(

address : IN STD_LOGIC_VECTOR (4 DOWNTO 0);

clock : IN STD_LOGIC ;

q : OUT STD_LOGIC_VECTOR (15 DOWNTO 0)

);

end component;

For example, if i want to know the value stocked in address "00000", how can i do ?

Thank you very much for your responses !!!! :)

1 Reply

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    you need to provide a clock to your clock port, provide the address "00000" to the address port, and check the q output after a number clock cycles from when you provide the desired address. the number of clock cycles is equal to your latency, or pipelining of the ROM