DSPRelated.com
Forums

Tone Indentification

Started by vbbrett November 23, 2005
Jerry Avins wrote:
> vbbrett wrote: > > Why does the 8 samples per cycle make the algoritm easier to implement? > > How does the number of samples affect the output? Why can't I just > > check 88 samples for a particular frequency? I'm afraid I don't > > understand the restrictions that are placed on the FFT or this Goertzel > > algorithm. > > It's possible to characterize a signal with just two samples per cycle.
Not if the signal's duration is only 22 mS. Time limited signals require more than 2 samples per cycle by a finite amount in order to characterize, even in zero noise. The more samples per cycle, the less cycles it should take to determine the likely frequency. IMHO. YMMV. -- rhn A.T nicholson d.O.t C-o-M
Ron N. wrote:
> Jerry Avins wrote: > >>vbbrett wrote: >> >>>Why does the 8 samples per cycle make the algoritm easier to implement? >>> How does the number of samples affect the output? Why can't I just >>>check 88 samples for a particular frequency? I'm afraid I don't >>>understand the restrictions that are placed on the FFT or this Goertzel >>>algorithm. >> >>It's possible to characterize a signal with just two samples per cycle. > > > Not if the signal's duration is only 22 mS. Time limited signals > require more than 2 samples per cycle by a finite amount in > order to characterize, even in zero noise. The more samples > per cycle, the less cycles it should take to determine the likely > frequency. > > > IMHO. YMMV.
2 samples/cycle is a limit that can't be reached in practice. 22 ms at 1400 Hz is more than 30 cycles. With that, not much oversampling is needed. With 4x oversampling, the issue isn't worth considering here. Jerry -- Engineering is the art of making what you want from things you can get. �����������������������������������������������������������������������
vbbrett wrote:
> Your first question was slightly confusing. If you asked how free of > noise the buffer is, then I will say that in real life it may have > quite a bit of noise, but not enough to injure the wave in any way. > Perhaps the same amount of noise you would get over a short distance > phone call. No, there won't be any other frequencies on the line, if > there are any, it will just be 1800 and 1400. Plus or Minus 3%. The > buffer that I analyze will not have just a single frequency in it. It > may go back and forth between the two several times. Each tone will be > exhibited for only 22 miliseconds. > > I don't think I can count the period of the wave, if that's what you > meant. The buffer does not show every single change in the wave. It > may only show 8 different values for a single period. > > > Brett >
It sounds like you are trying to decode TDD - that is the only place I have seen those two tones used. If that is the case, you are not looking at this in an efficient manner. What you need is an FSK modem, and you will find several efficient architectures for this which will work in very poor signal to noise conditions. Try a scan of the archive for this list. There were recent discussions about quadrature correlation, quadri-correlation, or whatever people like to call it. That is a very good method for decoding FSK signals. Steve
Hello Brett,

Just FWIW Circuit Cellar had some good articles about frequency 
detection using Goertzel. Here is one implemented on a Renesas uC:
http://www.circuitcellar.com/library/print/1004/Zhang/index.htm

It gets interesting on page 4.

IIRC there is also an article by Steve Garcia about simplifying the 
final Goertzel calc since you likely won't need real and imaginary.

If there isn't much uC horsepower left to do the calcs check out TI app 
note SLAAE16. It describes how to use wave digital filters (WDF) to 
increase the tolerance for coarser coefficients. That cuts down on 
shift-add operations for situations where you don't have a HW muliplier 
on board.

Zero crossing detection is what I did mostly in the past but usually 
with some analog pre-filtering and feeding into separate comparator 
ports. Not sure if that's going to be good enough for you here, it 
depends on the noise tolerance you need.

Regards, Joerg

http://www.analogconsultants.com