Professional Documents
Culture Documents
library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
entity muxfinalju is
en21 : in STD_LOGIC;
end muxfinalju;
begin
process(s21,en21,a21)
begin
if en21='1' then
case s21 is
end case;
end if;
end process;
end Behavioral;
test bench
--------------------------------------------------------------------------------
-- Company:
-- Engineer:
--
-- Design Name:
-- Target Device:
-- Tool versions:
-- Description:
--
--
-- Dependencies:
--
-- Revision:
-- Additional Comments:
--
-- Notes:
-- This testbench has been automatically generated using types std_logic and
-- std_logic_vector for the ports of the unit under test. Xilinx recommends
-- that these types always be used for the top-level I/O of a design in order
-- simulation model.
--------------------------------------------------------------------------------
LIBRARY ieee;
USE ieee.std_logic_1164.ALL;
--USE ieee.numeric_std.ALL;
ENTITY mux12 IS
END mux12;
PORT(
en21 : IN std_logic;
);
END COMPONENT;
--Inputs
--Outputs
BEGIN
);
-- <clock>_process :process
-- begin
-- end process;
-- Stimulus process
stim_proc: process
begin
a21(0)<='0';
a21(0)<='1';
end process;
stim_proc1: process
begin
a21(1)<='0';
a21(1)<='1';
a21(1)<='0';
end process;
stim_proc2: process
begin
a21(2)<='0';
a21(2)<='1';
a21(2)<='0';
end process;
stim_proc3: process
begin
a21(3)<='0';
a21(3)<='1';
a21(3)<='0';
wait for 300 ns;
end process;
stim_proc4: process
begin
a21(4)<='0';
a21(4)<='1';
a21(4)<='0';
end process;
stim_proc5: process
begin
a21(5)<='0';
a21(5)<='1';
a21(5)<='0';
end process;
stim_proc6: process
begin
a21(6)<='0';
a21(6)<='1';
wait for 100 ns;
a21(6)<='0';
end process;
stim_proc7: process
begin
a21(7)<='0';
a21(7)<='1';
a21(7)<='0';
end process;
stim_proc8: process
begin
s21(0)<=not s21(0);
end process;
stim_proc9: process
begin
s21(1)<=not s21(1);
end process;
stim_proc10: process
begin
s21(2)<=not s21(2);
end process;
stim_proc11: process
begin
en21<=not en21;
end process;
END;
Technology schematic
Jk flip
library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
entity jkflip is
begin
process(c,j,k)
begin
q12<='0';
q12<='1';
q12<= q12;
end if;
end if;
end process;
end Behavioral;
jk test bench
LIBRARY ieee;
USE ieee.std_logic_1164.ALL;
ENTITY jktest IS
END jktest;
PORT(
j : IN std_logic;
k : IN std_logic;
c : IN std_logic;
);
END COMPONENT;
BEGIN
j => j,
k => k,
c => c,
);
c_process :process
begin
c <= '0';
c <= '1';
stim_proc: process
begin
j<= not j;
end process;
stim_proc1: process
begin
k<= not k;
end process;
END;
Rtl schematic