问题描述:
cnt自加之后,为什么是从“000000”变为“00000X”,而不是“000001”,“000010”……呢?代码如下:
signal cnt : std_logic_vector (23 downto 0);
count_pro: process(clk, reset)
begin
if reset = '1' then
cnt <= (others => '0');
elsif rising_edge(clk) then
if cpu_beat_begin = '1' then
if cpun_rw = '1' then
cnt <= (others => '0');
else
cnt <= cnt + 1;
end if;
end if;
end if;
end process count_pro;
问题解答:
VHDL中计数器自加的问题这个旅游问答期待您的解答,请登录账号或关注微信公众号回答这个问题。