entity box2 is
port(S:in std_logic_vector(3 downto 0);
M ut std_logic_vector(3 downto 0));
end box2;
architecture Behavioral of box2 is
begin
with S select
M<="1111" when "0001",
"1110" when "0010",
"1101" when "0011",
"1100" when "0100",
"1011" when "0101",
"1010" when "0110",
"1001" when "0111",
"1000" when "1000",
"0111" when "1001",
"0110" when "1010",
"0101" when "1011",
“0100" when "1100",
"0011" when "1101",
"0010" when "1110",
"0001" when "1111",
"0000" when others;
end Behavioral; |