otsdaq_prepmodernization  v2_05_02_indev
MUX16_2.vhd
1 ----------------------------------------------------------------------------------
2 -- Company:
3 -- Engineer:
4 --
5 -- Create Date: 13:40:09 06/18/2008
6 -- Design Name:
7 -- Module Name: MUX16_2 - Behavioral
8 -- Project Name:
9 -- Target Devices:
10 -- Tool versions:
11 -- Description:
12 --
13 -- Dependencies:
14 --
15 -- Revision:
16 -- Revision 0.01 - File Created
17 -- Additional Comments:
18 --
19 ----------------------------------------------------------------------------------
20 library IEEE;
21 use IEEE.STD_LOGIC_1164.ALL;
22 use IEEE.STD_LOGIC_ARITH.ALL;
23 use IEEE.STD_LOGIC_UNSIGNED.ALL;
24 
25 ---- Uncomment the following library declaration if instantiating
26 ---- any Xilinx primitives in this code.
27 --library UNISIM;
28 --use UNISIM.VComponents.all;
29 
30 entity MUX16_2 is
31  Port ( in0 : in STD_LOGIC_VECTOR (15 downto 0);
32  in1 : in STD_LOGIC_VECTOR (15 downto 0);
33  sel : in STD_LOGIC;
34  muxout : out STD_LOGIC_VECTOR (15 downto 0));
35 end MUX16_2;
36 
37 architecture Behavioral of MUX16_2 is
38 
39 begin
40 
41  process(sel,in0,in1)
42  begin
43  if sel = '0' then
44  muxout <= in0;
45  else
46  muxout <= in1;
47  end if;
48  end process;
49 
50 end Behavioral;
51