Electronic – Analog Max Frequency Detector Circuit

frequency-measurement

As a follow up to this question: How to sample audio at Nyquist frequency with MSP430F5438?

What type of circuit would I use to generate something that a microcontroller could use to determine the max frequency of an input? I was thinking it would preferably provide a voltage that is lineally related to the frequency.

The information provided by the frequency detector could then be used by the microcontroller to know what frequency it needed to be sampled at.

Is there any ICs that do this? or any circuit that will do this?

Best Answer

I had two fleeting thoughts:

  1. One could use a crossover, which is an implementation of several bandpass filters, followed by power measurement in order to obtain a rough power spectral density. The highest frequency pass-band achieving a threshold would indicate maximum significant input frequency. If each crossover channel were input to trigger/comparator interrupt pins, some good debounce code may be able to take care of the rest. The crossover could be as simple as an array of diode detectors with RC filtering. Circuit complexity would be dependent on the bandwidth and resolution of the crossover. I'm sure we've all ooo'd & aaw'd at quality audio crossovers; diode detectors are very simple; RF range adds complications, but can use diode detectors as well.

  2. One could mix down the input frequency, followed by a LPF. Using a continous LO frequency, start at some minimum (~kHz) and increasing to a maximum expected frequency (20 kHz for audio), one could setup a trigger based on a threshold DC or low frequency output, or just record and compare over the entire range. I've never looked for a low frequency mixer, but it would be simple to make a crude one (diode bridge; Gilbert cell); RF mixer ICs are available.

Both of these methods are inferior to oversampling, but much more fun. There are frequency-to-voltage conversion ICs (DigiKey: PMIC - V/F and F/V Converters, 1MHz max).