You could measure it by counting the number of pulses every 100 msec. However, you will only have an resolution of 10 Hz that way, which probably isn't good enough.
You can greatly increase your accuracy by counting the number of pulses and recording when each one occurs. Subtract the time of the first pulse from the last pulse. Divide the number of pulses minus one by the time interval, and you have the pulse frequency.
If the frequencies are going to be less than 20 Hz, you will need to keep track of when the last pulse occurred in the previous block. Otherwise, it will alternate between 0 and 10 Hz as an output.
You could also use Extract Single Tone like you suggested. It will output the primary frequency of a square wave just as well as a sine wav
e. You would want to set your sample rate so that each block of data you analyze is a power of two. This only works for frequencies above 20 Hz, for the same reason - it requires two pulses in one block to work properly.
Bruce
Bruce Ammons
Ammons Engineering