adder.vhd

来自「多功能函数发生器」· VHDL 代码 · 共 18 行

VHD
18
字号
library ieee;
use ieee.std_logic_1164.all;
use ieee.std_logic_unsigned.all;
entity adder is
  port(load: in std_logic;
       a:in std_logic_vector(15 downto 0);
       b:in std_logic_vector(15 downto 0);
       s: out std_logic_vector(15 downto 0));
  end adder;
architecture behav of adder is
begin
process(load)
begin
if load'event and load='1'
   then s<=a+b;
end if;
end process;
end behav;

⌨️ 快捷键说明

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