我写了个跟踪输入波形的程序,但下载到板子上老是执行一段时间就跑飞了,怎么回事了?? elsif rst='1' and rising_edge(clk) then case current_state is when s0 => if cs='0' then temp:=0; current_state<=next_state; csbuf<='0'; end if; when s1 => if cs='1' then current_state<=next_state; csbuf<='1'; end if; when s2=> -- if temp/=n then -- temp:=temp+1; -- else -- temp:=0; current_state<=next_state; -- end if; when s3 => -- csout<='0'; current_state<=next_state; when others => current_state <= s0; end case;
|