pulseIn() function problem for measure frequency

Realistically if the OP is after frequency he only needs to measure the time between rising edges using an interrupt.

Duane B