📄 jkchu.vhd
字号:
library ieee;
use ieee.std_logic_1164.all;
entity jkchu is
port(j,k: in std_logic;
clk: in std_logic;
q: buffer std_logic;
qbar: out std_logic);
end entity;
architecture first of jkchu is
signal x: std_logic_vector(1 downto 0);
begin
x<=j & k;
process(clk,q)
begin
if(clk'event and clk='1' and clk'last_value='0') then
case x is
when "10" => q<=j;
when "01" => q<=j;
when "00" => q<=not q'last_value;
when "11" => q<=q'last_value;
end case;
end if;
qbar<= not q;
end process;
end first;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -