shaiko
Advanced Member level 5
Hello,
Suppose our application has to detect an incoming short pulse - faster than any of our clocks can sample reliably (or perhaps we don't even know the width of the incoming pulse).
My solution:
1. Drive the short signal (our_short_pulse) into a clock pin of a DFF (sadly wasting a BUFG).
2. Issue a detection flag (short_pulse_detected) to the slow clock domain.
3. Issue a reset signal to the detector (short_pulse_acknowledge).
So far, so good - I thought...
But than I found this interesting post:
What are the benefits of using the suggested method over my simple solution ?
Suppose our application has to detect an incoming short pulse - faster than any of our clocks can sample reliably (or perhaps we don't even know the width of the incoming pulse).
My solution:
1. Drive the short signal (our_short_pulse) into a clock pin of a DFF (sadly wasting a BUFG).
2. Issue a detection flag (short_pulse_detected) to the slow clock domain.
3. Issue a reset signal to the detector (short_pulse_acknowledge).
Code:
process (short_pulse_acknowledge , our_short_pulse) is
begin
if short_pulse_acknowledge = '1' then
short_pulse_detected <= '1' ;
elsif rising edge ( our_short_pulse ) then
short_pulse_detected <= '1' ;
end if ;
end process ;
So far, so good - I thought...
But than I found this interesting post:
What are the benefits of using the suggested method over my simple solution ?