Documentos de Académico
Documentos de Profesional
Documentos de Cultura
FISEI
Ingeniera en Electrnica y Comunicaciones
VLSI- DEBER
Integrantes:
Abigail Alds.
Edwin Gavilnez.
Christian Silva.
Daniela Sevilla.
Roberto Villacs.
Oscar Guzman.
CDIGO VHDL
FLIP-FLOP-D
library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
entity flip_f_d is
Port ( d ,r: in STD_LOGIC;
clk : in STD_LOGIC;
q : out STD_LOGIC);
end flip_f_d;
architecture Behavioral of flip_f_d is
begin
process (clk)
begin
if(clk'event and clk='1') then
q<= d;
end if;
end process;
end Behavioral;
INSTANCIACIN
TABLA DE VERDAD
X
0
0
0
0
1
1
1
1
A
0
0
1
1
0
0
1
1
B
0
1
0
1
0
1
0
1
A+
0
0
0
X
1
0
1
X
B+
1
1
0
X
0
0
0
X
DA
0
0
0
X
1
0
1
X
ECUACIONES
DA = AB +XB|
DB = X|A| + X|B
Y = X|AB| + XA|B
MAQUINA DE MOORE
DB
1
1
0
X
0
0
0
X
Y
0
0
1
0
0
1
0
0
1
0
1
0
0
1
0
1
Entidad
Cdigo
library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
entity MOORE is
Port ( dato, clk, ena : in STD_LOGIC;
q0 : out STD_LOGIC;
q1 : out STD_LOGIC);
end MOORE;
architecture
type estados
signal sali:
signal aux1:
signal aux2:
begin
Behavioral of MOORE is
is (a,b,c,d,e);
std_logic_vector(1 downto 0);
estados;
estados;
--inclusin de la librera.
--declaracin de la entidad.
--declaracin de puertos.
--final de la entidad
--inicio de arquitectura
--variable enumerada creada.
-- signal para ayudarnos.
process (clk,ena)
begin
if (ena='0')then
aux2<=a;
elsif (ena='1')then
aux2<=aux1;
case aux1 is
when a =>
if (dato='1')then
aux1<=e;
else
--condicin enable.
--asignacin de estado
--siguiente.
aux1<=b;
end if;
when b =>
if (dato='1')then
aux1<=c;
else
aux1<=b;
end if;
when c=>
if (dato='1')then
aux1<=e;
else
aux1<=d;
end if;
when d =>
if (dato='1')then
aux1<=c;
else
aux1<=b;
end if;
when e =>
if (dato='1')then
aux1<=e;
else
aux1<=d;
end if;
end
end
end
end
case;
if;
if;
process;