Hola quisiera que alguin me pudiera ayudar con este circuito ya que por mas que intento se ni como hacerle, ya he intentado hacer cambios pero no me sale.
Solo tengo que incluir la parte de los mux y el sumador pero la verdad no se como, espero que alguien me dijera que tengo que hacer mas o menos
http://imageshack.us/photo/my-images/254/sinttulohze.png/
Miren esto es lo que escribi pero me da muchos errores
Library IEEE;
use IEEE.std_logic_1164.all;
use IEEE.std_logic_unsigned.all;
use IEEE.numeric_std.all;
entity Sumador is
port (A,I:in std_logic_vector(3 downto 0);
sel:in std_logic_vector(1 downto 0);
S
ut std_logic_vector(3 downto 0);
Co
ut std_logic);
end Sumador;
architecture Arch of Sumador is
signal B:std_logic;
signal y:std_logic;
signal t1:std_logic;
signal t2:std_logic;
signal t3:std_logic;
signal c :std_logic;
signal c1:std_logic;
signal c2:std_logic;
signal c3:std_logic;
begin
process (sel,I)
begin
case sel is
when "00" => y <= '0';
when "01" => y <= I;
when "10" => y <= not I;
when others => y <= '1';
end case;end process;
process(A,B)
begin
S(0)<= (A(0) AND NOT b1) OR (NOT A(0) AND b1);
c <= (A(0) AND b1);
t1 <= (A(1) AND NOT b2) OR (NOT A(1) AND b2);
S(1)<= (t1 AND NOT c) OR (NOT t1 AND c);
c1 <= (A(1) AND b2) OR (A(1) AND c)OR (c AND b2);
t2 <= (A(2) AND NOT b3) OR (NOT A(2) AND b3);
S(2)<= (t2 AND NOT c1) OR (NOT t2 AND c1);
c2 <= (A(2) AND b3) OR (A(2) AND c1)OR (c1 AND b3);
t3 <= (A(3) AND NOT b4) OR (NOT A(3) AND b4);
S(3)<= (t3 AND NOT c2) OR (NOT t3 AND c2);
c3 <= (A(3) AND b4) OR (A(3) AND c2)OR (c2 AND b4);
end process;
A(0)<= '0';A(3)<= '0';
A(1)<= '1';A(2)<= '1';
Co<= c3;
y<= B;
end Arch;
Espero que me puedan ayudar
Gracias
Solo tengo que incluir la parte de los mux y el sumador pero la verdad no se como, espero que alguien me dijera que tengo que hacer mas o menos
http://imageshack.us/photo/my-images/254/sinttulohze.png/
Miren esto es lo que escribi pero me da muchos errores
Library IEEE;
use IEEE.std_logic_1164.all;
use IEEE.std_logic_unsigned.all;
use IEEE.numeric_std.all;
entity Sumador is
port (A,I:in std_logic_vector(3 downto 0);
sel:in std_logic_vector(1 downto 0);
S
Co
end Sumador;
architecture Arch of Sumador is
signal B:std_logic;
signal y:std_logic;
signal t1:std_logic;
signal t2:std_logic;
signal t3:std_logic;
signal c :std_logic;
signal c1:std_logic;
signal c2:std_logic;
signal c3:std_logic;
begin
process (sel,I)
begin
case sel is
when "00" => y <= '0';
when "01" => y <= I;
when "10" => y <= not I;
when others => y <= '1';
end case;end process;
process(A,B)
begin
S(0)<= (A(0) AND NOT b1) OR (NOT A(0) AND b1);
c <= (A(0) AND b1);
t1 <= (A(1) AND NOT b2) OR (NOT A(1) AND b2);
S(1)<= (t1 AND NOT c) OR (NOT t1 AND c);
c1 <= (A(1) AND b2) OR (A(1) AND c)OR (c AND b2);
t2 <= (A(2) AND NOT b3) OR (NOT A(2) AND b3);
S(2)<= (t2 AND NOT c1) OR (NOT t2 AND c1);
c2 <= (A(2) AND b3) OR (A(2) AND c1)OR (c1 AND b3);
t3 <= (A(3) AND NOT b4) OR (NOT A(3) AND b4);
S(3)<= (t3 AND NOT c2) OR (NOT t3 AND c2);
c3 <= (A(3) AND b4) OR (A(3) AND c2)OR (c2 AND b4);
end process;
A(0)<= '0';A(3)<= '0';
A(1)<= '1';A(2)<= '1';
Co<= c3;
y<= B;
end Arch;
Espero que me puedan ayudar
Gracias
Última edición: