Forum Discussion
Altera_Forum
Honored Contributor
15 years agoLoop index overflow problem
Hi there, I've wrote a little VHDL program in Quartus II. I'd like to separate one big std_logic_vector into small fix-length std_logic_vectors and the compile told me that the index is out...
Altera_Forum
Honored Contributor
15 years ago --- Quote Start --- thats because j stops at 504, and you print j+7 I dont see a p_count + 7 offset anywhere in your VHDL. You'll find that j actually finishes the loop on 512. --- Quote End --- i wrote this, p := datain(p_count+i_width-1 downto p_count); --i_width=8, so this is my "p_count+7" p_count:=p_count+i_width;