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

📄 fenpin.vhd

📁 用NEC编码方式写的红外发送程序,包括三个部分,分频,编码,编码输出
💻 VHD
字号:
library ieee;                          --1.5MHz分频为38KHz
use ieee.std_logic_1164.all;
use ieee.std_logic_unsigned.all;
entity fenpin is
port(clk:in std_logic;
     div40:out std_logic);
end;
architecture one of fenpin is
  signal cnt:std_logic_vector(4 downto 0);
  signal clk_temp:std_logic;
  constant m:integer:=19;
begin
process(clk)
begin
if clk'event and clk='1' then
    if cnt=m then
        clk_temp<=not clk_temp;
        cnt<="00000";
    else
        cnt<=cnt+1;
    end if;
end if;
end process;
div40<=clk_temp;
end;

⌨️ 快捷键说明

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