library IEEE;
use IEEE.std_logic_1164.all;
use IEEE.numeric_std.all;
use IEEE.std_logic_unsigned.all;
-- use work.EDAC.all;

entity Hamming4 is
   port(
      DataOut:       in    std_logic_vector(0 to 3);    -- Output data bits
      CheckOut:      out   std_logic_vector(0 to 3);    -- Output check bits

      DataIn:        in    std_logic_vector(0 to 3);    -- Input data bits
      CheckIn:       in    std_logic_vector(0 to 3);    -- Input check bits

      DataCorr:      out   std_logic_vector(0 to 3);    -- Corrected data bits
      SingleErr:     out   Std_ULogic;          -- Single error
      DoubleErr:     out   Std_ULogic;          -- Double error
      MultipleErr:   out   Std_ULogic          -- Uncorrectable error
   );
end Hamming4;