?? alarm.vhd
字號(hào):
--alarm
library ieee;
use ieee.std_logic_1164.all;
use ieee.std_logic_unsigned.all;
entity alarm is
port(mh,m,sh,s:in std_logic_vector(3 downto 0);
clk1,clk2,co:in std_logic;
q:out std_logic);
end alarm;
architecture rtl of alarm is
signal q1:std_logic;
begin
process(mh,m,sh,s,co)
begin
if co='1' then
if mh="0101" and m="1001" then
if sh="0101" and (s(2)='1' or s(3)='1') then
q1<=clk1;
end if;
elsif mh="0000" and m="0000" then
if sh="0000" and s="0000" then
q1<=clk2;
end if;
end if;
end if;
end process;
q<=q1;
end rtl;
?? 快捷鍵說(shuō)明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -