⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 conkeep.vhd

📁 电子抢答器 系统复位后进行抢答.超前抢答显示犯规信号
💻 VHD
字号:
library ieee;
use ieee.std_logic_1164.all;
use ieee.std_logic_unsigned.all;

entity conkeep is port
	(	
	 	reset		:in std_logic;
	 	s			:in std_logic_vector(3 downto 0);
	 	decodeout	:buffer	std_logic_vector(6 downto 0);
		f			:buffer std_logic
	);
end conkeep;

architecture truthtable of conkeep is
begin
	f<='0'when(decodeout="1111110")else'1';
	process(s,reset)
	begin
		if(reset='1')then
			decodeout<="1111110";
			elsif(f='0')then
				case s is
					when "0000"=>decodeout<="1111110";
					when "0001"=>decodeout<="0110000";
					when "0010"=>decodeout<="1101101";
					when "0100"=>decodeout<="1111001";
					when "1000"=>decodeout<="0110011";
					when others=>decodeout<="1111011";
				end case;
		end if;		
	end process;
end truthtable;

⌨️ 快捷键说明

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