hi every body
this is my code
m is the output of my for-generate statement.
i wanna save the value of m in Avrg , every loop .
i mean in the first loop i want to save m in the LSB of Avrg(0)
in the second , save it in Avrg(1)
etc.
what should i replace with question mark?
this is my code
Code:
architecture structure of main is
.....
begin
L1:for s in 0 to N-1 generate
L2:for t in 0 to 2**s-1 generate
-- Output index
constant output_index : integer := (2**s-1) + t;
-- Input indices (based on the output index)
constant input_index_start : integer := 2*output_index+1 ;
constant input_index_end : integer := 2*output_index + 2;
begin
DUT: entity work.trans
port map (
rstN => rstN,
clk => clk,
data => n(input_index_end downto input_index_start),
i => n(output_index),
d => m(output_index)
);
Avrg(???????????)<=m(output_index);
end generate;
end generate;
i wanna save the value of m in Avrg , every loop .
i mean in the first loop i want to save m in the LSB of Avrg(0)
in the second , save it in Avrg(1)
etc.
what should i replace with question mark?