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

📄 cnt1000.vhd

📁 fpga的应用
💻 VHD
字号:
library ieee;
use ieee.std_logic_1164.all;
use ieee.std_logic_unsigned.all;
entity cnt1000 is
  port(clk,en:in std_logic;
       cq:out std_logic_vector(9 downto 0));
end cnt1000;

architecture behav of cnt1000 is
signal q:std_logic_vector(9 downto 0);
begin 
process(clk,en)    
 begin
    if clk'event and clk='1' then  
       if en='1' then
           if q="1111100111" then 
			  q<="0000000000";
           else q<=q+'1';
           end if;
		else q<="0000000000";
        end if;
     end if;
    cq<=q;
  end process;
end behav;

⌨️ 快捷键说明

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