Entity: HammingEccTb

Diagram

Description


Title : Hamming-ECC: https://en.wikipedia.org/wiki/Hamming_code

Company : SLAC National Accelerator Laboratory

Description: Testbench for design "hamming-ecc"

This file is part of 'SLAC Firmware Standard Library'. It is subject to the license terms in the LICENSE.txt file found in the top-level directory of this distribution and at: https://confluence.slac.stanford.edu/display/ppareg/LICENSE.html. No part of 'SLAC Firmware Standard Library', including this file, may be copied, modified, propagated, or distributed except according to

the terms contained in the LICENSE.txt file.

Signals

Name Type Description
r RegType
rin RegType
clk sl
rst sl
encValid sl
encData slv(ENC_WIDTH_C downto 0)
encDataMask slv(ENC_WIDTH_C downto 0)
obValid sl
obData slv(DATA_WIDTH_C-1 downto 0)
obErrSbit sl
obErrDbit sl
passed sl
failed sl

Constants

Name Type Value Description
CLK_PERIOD_C time 4 ns
TPD_G time CLK_PERIOD_C/4
DATA_WIDTH_C positive 8
ENC_WIDTH_C positive hammingEccDataWidth(DATA_WIDTH_C)
k positive DATA_WIDTH_C Useful values to see in simulation
m positive hammingEccPartiyWidth(k)
n positive hammingEccDataWidth(k)
REG_INIT_C RegType ( passed => '0',
failed => '0',
ibValid => '0',
ibData => (others => '0'),
bitErrorMask => (others => '0'),
state => LOAD_S)

Types

Name Type Description
StateType ( LOAD_S,
WAIT_S,
FAILED_S,
PASSED_S)
RegType

Processes

Description
----------------------------------------------- FSM to sweep through all possible combination ----------------------------------------------

Instantiations

Description

Modules to be testing

Description
Insert the bit error