Binome
Full Member level 3
- Joined
- Nov 16, 2009
- Messages
- 153
- Helped
- 2
- Reputation
- 4
- Reaction score
- 2
- Trophy points
- 1,298
- Location
- Lyon, France
- Activity points
- 2,412
Please tell me what difference there is between these 2 kinds of loop:
Thank you.
Code:
init1 : process(clk,rst)
begin
init_loop : for j in 0 to N-1 loop
if rst='1' then
sigtmp_I(0,j) <= (others => '0');
sigtmp_Q(0,j) <= (others => '0');
elsif rising_edge(clk) then
sigtmp_I(0,j) <= in_ifft_I(j);
sigtmp_Q(0,j) <= in_ifft_Q(j);
end if;
end loop init_loop;
end process init1;
init2 : for j in 0 to N-1 generate
if rst='1' then
sigtmp_I(0,j) <= (others => '0');
sigtmp_Q(0,j) <= (others => '0');
elsif rising_edge(clk) then
sigtmp_I(0,j) <= in_ifft_I(j);
sigtmp_Q(0,j) <= in_ifft_Q(j);
end if;
end generate init2;