kcompare.vhd

来自「数字密码引爆器的输入描述:1、 在开始输入密码以前的等待状态」· VHDL 代码 · 共 28 行

VHD
28
字号
library ieee;
use ieee.std_logic_1164.all;
use ieee.std_logic_unsigned.all;


entity kcompare is 
  port( A,B,C,D: IN std_logic;
		E,F,G,H: IN std_logic;
 		CLK:IN std_logic;
        result: OUT std_logic);
end entity;

architecture kcom_behave of kcompare is
begin
  process(CLK)
   begin
     if(CLK'EVENT and CLK='1')then
    	 if(A=E and B=F and C=G and D=H)then
      		 result<='1';
    	 else 
       		result<='0';
     	 end if;
     end if;
   end process;

end kcom_behave;

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?