You could use a Timer that is set for a little longer than the span between pulses. Each pulse resets the timer and increments the counter. When the Timer times out, lock in your Counter as your...