URL
https://opencores.org/ocsvn/t80/t80/trunk
[/] [t80/] [trunk/] [rtl/] [vhdl/] [SSRAMX.vhd] - Diff between revs 41 and 46
Go to most recent revision |
Show entire file |
Details |
Blame |
View Log
Rev 41 |
Rev 46 |
Line 88... |
Line 88... |
type bRAMOut_a is array(0 to RAMs - 1) of std_logic_vector(7 downto 0);
|
type bRAMOut_a is array(0 to RAMs - 1) of std_logic_vector(7 downto 0);
|
|
|
signal bRAMOut : bRAMOut_a;
|
signal bRAMOut : bRAMOut_a;
|
signal biA_r : integer;
|
signal biA_r : integer;
|
signal A_r : unsigned(A'left downto 0);
|
signal A_r : unsigned(A'left downto 0);
|
signal A_i : std_logic_vector(8 downto 0);
|
-- signal A_i : std_logic_vector(8 downto 0);
|
signal WEA : std_logic_vector(RAMs - 1 downto 0);
|
signal WEA : std_logic_vector(RAMs - 1 downto 0);
|
|
|
begin
|
begin
|
|
|
process (Clk)
|
process (Clk)
|
Line 101... |
Line 101... |
A_r <= unsigned(A);
|
A_r <= unsigned(A);
|
end if;
|
end if;
|
end process;
|
end process;
|
|
|
biA_r <= to_integer(A_r(A'left downto 9));
|
biA_r <= to_integer(A_r(A'left downto 9));
|
A_i <= std_logic_vector(A_r(8 downto 0)) when (CE_n nor WE_n) = '1' else A(8 downto 0);
|
-- A_i <= std_logic_vector(A_r(8 downto 0)) when (CE_n nor WE_n) = '1' else A(8 downto 0);
|
|
|
bG1: for I in 0 to RAMs - 1 generate
|
bG1: for I in 0 to RAMs - 1 generate
|
begin
|
begin
|
WEA(I) <= '1' when (CE_n nor WE_n) = '1' and biA_r = I else '0';
|
WEA(I) <= '1' when (CE_n nor WE_n) = '1' and biA_r = I else '0';
|
BSSRAM : RAMB4_S8
|
BSSRAM : RAMB4_S8
|
Line 113... |
Line 113... |
DI => DIn,
|
DI => DIn,
|
EN => '1',
|
EN => '1',
|
WE => WEA(I),
|
WE => WEA(I),
|
RST => '0',
|
RST => '0',
|
CLK => Clk,
|
CLK => Clk,
|
ADDR => A_i,
|
ADDR => A,
|
DO => bRAMOut(I));
|
DO => bRAMOut(I));
|
end generate;
|
end generate;
|
|
|
process (biA_r, bRAMOut)
|
process (biA_r, bRAMOut)
|
begin
|
begin
|
© copyright 1999-2025
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.