Guest
Hi
I do not have much expirience in VHDL and I'm stuck at (I hope) very
basic problem. I have this generic component (register):
COMPONENT reg
GENERIC (
data_width : integer := 32
);
PORT(
enable : IN std_logic;
clk : IN std_logic;
rst : IN std_logic;
load : IN std_logic;
data_in : IN std_logic_vector(31 downto 0);
data_out : OUT std_logic_vector(31 downto 0)
);
END COMPONENT;
Then I need two instances of the register, one 32-bit and one 16-bit.
When creating instance of 16-bit component, I get this error: "Width
mismatch. Expected width 32, Actual width is 16 for dimension 1 of
mem_out_adata."
MEMWB_ADATA: reg
GENERIC MAP (
data_width => 16
)
PORT MAP(
clk => clk,
rst => reset,
enable => enable,
load => mem_reg_we,
data_in => mem_out_adata,
data_out => wb_in_adata
);
Can anyone advise, please?
Best regards,
Zvonko
I do not have much expirience in VHDL and I'm stuck at (I hope) very
basic problem. I have this generic component (register):
COMPONENT reg
GENERIC (
data_width : integer := 32
);
PORT(
enable : IN std_logic;
clk : IN std_logic;
rst : IN std_logic;
load : IN std_logic;
data_in : IN std_logic_vector(31 downto 0);
data_out : OUT std_logic_vector(31 downto 0)
);
END COMPONENT;
Then I need two instances of the register, one 32-bit and one 16-bit.
When creating instance of 16-bit component, I get this error: "Width
mismatch. Expected width 32, Actual width is 16 for dimension 1 of
mem_out_adata."
MEMWB_ADATA: reg
GENERIC MAP (
data_width => 16
)
PORT MAP(
clk => clk,
rst => reset,
enable => enable,
load => mem_reg_we,
data_in => mem_out_adata,
data_out => wb_in_adata
);
Can anyone advise, please?
Best regards,
Zvonko