Forum Discussion

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

Replacing a process with 1-port RAM

i have process I need to now implement as ROM.

process (count, outi, run) --converter
     begin
        if (run = '1') then -- run is a physical switch
        case count is       -- count is the current value of a 2 bit counter
            when "00" =>
                outi <= "1000"; 
            when "01" =>
                outi <= "0100";
            when "10" =>
                outi <= "0001";
            when "11" =>
                outi <= "0010";    
            when others =>
                outi <= "0000";
            end case;
        end if;
     end process;

The output outi is assigned to LEDS outside the process.

I have created 1 port ram and created a mif file that looks like this

Addr

+0

+1

+2

+3

ASCII

0

1000

0100

0001

0010

...

But I'm not sure what exactly I need to do now.

I'm very to new to VHDL and FPGAs in general.