answersLogoWhite

0

library IEEE;

use IEEE.STD_LOGIC_1164.ALL;

use IEEE.STD_LOGIC_ARITH.ALL;

use IEEE.STD_LOGIC_UNSIGNED.ALL;

entity mux2x1 is

Port ( i : in STD_LOGIC_VECTOR (1 downto 0);

s : in STD_LOGIC;

y : out STD_LOGIC);

end mux2x1;


architecture df of mux2x1 is

begin

with s select

y<= i(0) when '0',

i(1) when '1',

'0' when others;

end df;

User Avatar

Wiki User

12y ago

Still curious? Ask our experts.

Chat with our AI personalities

BeauBeau
You're doing better than you think!
Chat with Beau
FranFran
I've made my fair share of mistakes, and if I can help you avoid a few, I'd sure like to try.
Chat with Fran
JordanJordan
Looking for a career mentor? I've seen my fair share of shake-ups.
Chat with Jordan

Add your answer:

Earn +20 pts
Q: What is VHDL program for 2 to 1 multiplexer?
Write your answer...
Submit
Still have questions?
magnify glass
imp