1 ------------------------------------------------------------------------------- 3 --! @brief Level-filter module 4 ------------------------------------------------------------------------------- 9 --! Using IEEE standard logic components 10 USE ieee.std_logic_1164.
ALL;
12 --! @brief Level-filter entity 14 --! This entity acts as a level-filter which changes when a signal is 15 --! stable at a level for the specified count. 18 count : RANGE 1 TO 'high := 2 --! Filter length 26 END ENTITY level_filter;
28 --! Architecture rtl of level_filter entity 31 --! Constant for all-high 34 --! Constant for all-low 35 CONSTANT c_low : (count - 2 DOWNTO 0) := (OTHERS => '0');
37 --! Input history shift register 45 --! @brief Shift process 53 ELSIF (rising_edge(clk_in)) THEN 71 -- Drive sig_out from current state std_logic_vector( count- 2 DOWNTO 0) history
Input history shift register.
out sig_outstd_logic
Output signal.
std_logic state
Current state.
in sig_instd_logic
Input signal.
in clk_instd_logic
Clock.
std_logic_vector( count- 2 DOWNTO 0) :=( others => '1') c_high
Constant for all-high.
in rst_instd_logic
Asynchronous reset.
std_logic_vector( count- 2 DOWNTO 0) :=( others => '0') c_low
Constant for all-low.
_library_ ieeeieee
Using IEEE library.
countnatural range 1 TO natural'high:= 2
Filter length.