登录站点

用户名

密码

周立功的开发板EasyFPGA030上的例程MUX_2的改写(语言:VHDL)

2已有 1068 次阅读  2009-10-30 08:38   标签VHDL  例程  周立功  MUX  语言 
--周立功的开发板EasyFPGA030上的例程MUX_2的改写(语言:VHDL)
-- mux_2.vhd
library ieee;
use ieee.std_logic_1164.all;
entity mux_2 is
    port(sel: in std_logic;
         indat: in std_logic_vector(1 downto 0);
         led : out std_logic);
end entity mux_2;
architecture rtl of mux_2 is
begin
    process(sel,indat)
    begin
        if(sel = '0') then
            led <= indat(0);
        else
            led <= indat(1);
        end if;
    end process;
end architecture rtl;
           

上一篇: VHDL编写的比较器 下一篇: 周立功开发板EasyFPGA030的LED历程改写(语言:VHDL),已经在开发板上验证

分享 举报

发表评论 评论 (1 个评论)

涂鸦板