开发者

Tuner application: How do find the frequency?

Greetings,

I am currently developing a tuner application using Silverlight/c# for class project. The problems i am having seem to be asked by quite a few people but not really answered. I have read a lot of forums and googled for hours but still cannot really grasp the code and math. What i have so far is thus:

Mic => audio input => audio samples are wrote to a memory stream => bytes converted to doubles then to complex numbers => FFT() which returns an array of complex numbers...

I have read about FFT/DFT/Autocorrelation/etc. It seems to me that FFT is the way i want to go for speed. I am, essentially, turning a chromatic tuner used in band/orchestra/etc into a online application so everything needs to be done real time. For now im just focusing on trying to understand the entire process.

Questions:

  1. What is the correct method of converting the bytes wrote to the memory stream to complex numbers? This is partially answered here Convert Audio samples from bytes to complex numbers?, but i do not know which is the correct method for each one results in different values.

  2. I understand the basics of FFT, but not exactly sure what the numbers represent at the different stages. For example, what exactly does the array of complex numbers represent when going into the ff开发者_开发问答t algorithm, and what do they represent when leaving?

  3. What other processing is required to find the freqency of the note being played after the FFT has been calculated?

I appreciate all the help, this project has proved to be more complicated than what i orginally researched! :/

Cheers and thanks!

Josh


1) Got nothin'

2) An FFT returns an array of values. Each array member contains the strength of the signal in that frequency band.

3) First, find the array member that has the strongest value. To dial in the exact frequency, you'll probably have to do some interpolation between the array members around the strongest bucket.

EDIT: Found this article. Looks like it breaks it down for you.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜