Advertisement
Guest User

Untitled

a guest
Oct 15th, 2019
102
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. library IEEE;
  2. use IEEE.STD_LOGIC_1164.ALL;
  3. use ieee.numeric_std.all;
  4.  
  5. entity Mux is
  6. Port ( input1 : in STD_LOGIC_VECTOR (12 downto 0);
  7. input2 : in STD_LOGIC_VECTOR (12 downto 0);
  8. S : in STD_LOGIC;
  9. MUXOUT : out STD_LOGIC_VECTOR (12 downto 0)
  10. );
  11. end Mux;
  12.  
  13. architecture Behavioral of Mux is
  14.  
  15. begin
  16. with S select
  17. MUXOUT <= input1 when '0',
  18. input2 when '1',
  19. "0000000000000" when others;
  20.  
  21.  
  22. end Behavioral;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement