我做了个10万的计数器,代码:
process(clk,ld)
begin
if ld='1' then
tcnt <=setup;
elsif(clk='1' and clk'event) then
if(tcnt=99999) then
tcnt <=0;
else
tcnt <=tcnt+1;
end if;
end if;
end process;
BIN <=TCNT;
编译仿真都没有问题,但是BIN输出的第8位(BIN7)总是0,其他位正常计数。
检查了外围电路,最后切断这一位的连线,还是不行,换片子也试验过了。 这一位适配在44脚。
请各位大侠指点迷津。