-------------------------------------------------------------------------------- -- Company: -- Engineer: -- -- Create Date: 19:27:34 09/16/2014 -- Design Name: -- Module Name: C:/Users/Student/Desktop/Workspace/hamming/encoder_test.vhd -- Project Name: hamming -- Target Device: -- Tool versions: -- Description: -- -- VHDL Test Bench Created by ISE for module: encoder -- -- Dependencies: -- -- Revision: -- Revision 0.01 - File Created -- 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 -- to guarantee that the testbench will bind correctly to the post-implementation -- simulation model. -------------------------------------------------------------------------------- LIBRARY ieee; USE ieee.std_logic_1164.ALL; -- Uncomment the following library declaration if using -- arithmetic functions with Signed or Unsigned values --USE ieee.numeric_std.ALL; ENTITY encoder_test IS END encoder_test; ARCHITECTURE behavior OF encoder_test IS -- Component Declaration for the Unit Under Test (UUT) COMPONENT encoder PORT( D : IN std_logic_vector(4 downto 1); B : OUT std_logic_vector(7 downto 1) ); END COMPONENT; --Inputs signal D : std_logic_vector(4 downto 1) := (others => '0'); --Outputs signal B : std_logic_vector(7 downto 1); -- No clocks detected in port list. Replace below with -- appropriate port name BEGIN -- Instantiate the Unit Under Test (UUT) uut: encoder PORT MAP ( D => D, B => B ); -- Stimulus process stim_proc: process begin -- hold reset state for 100 ns. wait for 10 ns; -- insert stimulus here D <= "0001"; wait for 10 ns; D <= "0010"; wait for 10 ns; D <= "0100"; wait for 10 ns; D <= "1000"; wait; end process; END;