1
0
SEm-Labos/zz-solutions/02-SplineInterpolator/SplineInterpolator/hdl/interpolatorTrigger_masterVersion.vhd

28 lines
575 B
VHDL
Raw Normal View History

2024-03-15 14:03:34 +00:00
ARCHITECTURE masterVersion OF interpolatorTrigger IS
signal triggerCounter: unsigned(counterBitNb-1 downto 0);
BEGIN
count: process(reset, clock)
begin
if reset = '1' then
triggerCounter <= (others => '0');
elsif rising_edge(clock) then
if en = '1' then
triggerCounter <= triggerCounter + 1;
end if;
end if;
end process count;
trig: process(triggerCounter, en)
begin
if triggerCounter = 0 then
triggerOut <= en;
else
triggerOut <= '0';
end if;
end process trig;
END ARCHITECTURE masterVersion;