📄 frequency_control.vhdl
字号:
library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
use IEEE.STD_LOGIC_ARITH.ALL;
use IEEE.STD_LOGIC_UNSIGNED.ALL;
entity control is
Port ( Bsignal : in std_logic;
Gate : out std_logic;
Reset : out std_logic;
latch : out std_logic);
end control;
architecture Behavioral of control is
signal G1,G2: std_logic:='0';
begin
process(Bsignal,G1)
begin
if rising_edge(Bsignal) then
G1<=not G1;
end if;
if falling_edge(bsignal) then
G2<=not G1;
end if;
end process;
gate<=G1;
latch<=G2;
reset<=(not bsignal)and(not G1)and (G2);
end Behavioral;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -