The ECC Encoder is used to generate the ECC check (or protection) bits for the input data (write data of the AXI4 slave). For every 8 bits of data input, it generates 5 check bits. The Hamming/Hsiao algorithm is used to generate check bits inside the ECC Encoder. These bits are used during each ECC Decoder operation to correct any single-bit errors, or to detect any double-bit errors. The data along with calculated check bits are provided as an output of ECC Encoder block. For details on the Hamming/Hsiao algorithm, see the ECC LogiCORE IP Product Guide (PG092).
The following is the block diagram of the ECC Encoder: