📄 sel.vhd
字号:
-----------------------------------------------------------------------
--该模块实现在停车场有汽车时,对8×8点阵的列选信号的确定
--本设计中列选信号是每过一个时钟周期就变化一次的
--通过这种快速的扫描实时输出停车场状态信息(即有没有有汽车进出)
-----------------------------------------------------------------------
library ieee;
use ieee.std_logic_1164.all;
use ieee.std_logic_unsigned.all;
entity sel is
port(
clk: in std_logic;
q : out std_logic_vector(2 downto 0)
);
end sel;
architecture sel of sel is
begin
process(clk)
variable cnt:std_logic_vector(2 downto 0);
begin
if clk'event and clk='1' then
cnt:=cnt+1;
end if;
q<=cnt;
end process;
end sel;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -