cnt2.vhd
来自「利用EDA工具MAX-PlusII的VDHL输入法」· VHDL 代码 · 共 20 行
VHD
20 行
library ieee;
use ieee.std_logic_1164.all;
entity cnt2 is
port (clk:in std_logic;
q:buffer integer range 0 to 3);
end cnt2;
architecture state of cnt2 is
begin
process(clk)
begin
if((clk'event)and(clk='1'))then
if (q=3) then q<=0;
else q<=q+1;
end if;
end if;
end process;
end state;
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?