Question about testing DACs dynamics range

This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.
Hello, it might sound stupid question but I could not find the answer so far...
I tried to understand why the DAC THD+N is being tested using 991kHz test tone. Same with 4x and 8x oversampling.
Trying to measure DAC dynamic range with 1kHz test tone gives lousy results: high values for 2nd and 3rd harmonics (for high quality multibit DACs).
Please, advise :)
What I noticed replacing the 1kHz test tone with 991Hz, it gives much more clear DAC output spectra, actually meeting the datasheet dinamics spec.
1kHz produces random placed on the x axis spikes... The FFT requirement for complete signal period is not fulfilled for both 1kHz and 991Hz for sampling frequency 44,1kHz...
I'm really brainteased with this puzzle :xeye:
Then you get an integer number of samples in a full sine period. For example there are 45 samples in 44.1 kHz sample periods. The individual samples in each consecutive sample period fall at the same point of the sine wave. E.g. if the first and 23rd is at zero crossing, then the 46th is again at zero crossing etc.
The FFT requrement for the test signal is just what you say, but for the given example I can not fully agree :(
The period of 991Hz does not contain integer number of 44100Hz periods (samples), but some 44,50050454086781029263370332997.
I checked this before posting my question above...or my calculator is not trusty anymore ;)
I generate 1kHz sin using Adobe audition. The noise floor of the generated signal is -136dB as reported by Adobe and Cooledit. The same signal recorded on CD and extracted from it, again spectrum analized gives the same -136dB noise floor and the respective 1kHz fundamental tone magnitude (-10, -20 ... -60dB as recorded on diffrenet tracks). So I do not suspect the recorded test tone signal, neither the generation process itself but a test problem related to FFT analyses (or whatever they use in spectrum analysators) ... After a day of thinking why so extremely good sounding DACs measure so bad spectrum I noticed Burr Brown test condition: 991Hz test tone, what proved to be giving the correct results. The question "Why?" is still unanswered....
You don't need to have an integer number of cycles in the 44100-sample period for the FFT to work well - you need an integer number of cycles inside the FFT window, so that the signal appears continuous as far as the FFT is concerned. An implication of this is that the signal frequency will land exactly on an FFT bin.

In this case, it depends on the length of the FFT used. With a 32k FFT, at 44.1kHz, a 991Hz tone is quite close to an FFT bin (~0.5 Hz from the nearest), so you can take an FFT without worrying about applying a window function. As the FFT gets shorter, this signal will get further and further away from the nearest bin, and the FFT will show more and more spectral leakage.

That is my guess as to what you are observing.
Thinking about this a little more, I don't think I explained it well...

Can you give details about how you're taking your measurements? Can you post a pic?

Essentially, as in my last post, it's important to use a signal frequency that fits exactly into an FFT bin when taking FFT measurements, so that you get an integer number of cycles within the window. This requires that you select a suitable frequency for each samplerate/FFT-length combination.

For example, when I take digital->digital measurements at 44.1kHz, I tend to use a 16k-FFT (which gives a bin width of 2.69165Hz) and an input frequency of 9.99948kHz. This is close to 10kHz but resides in the 3715th FFT bin, and thus does not require a window function to be applied in order to avoid spectral leakage.
This measurement places the 24-bit noise floor at around -180dBFS.
Originally posted by beauty_divine
However, I can clearly see the artefacts when measuring 1kHz sin signal and theay are definitely away when 991Hz is in use.

That does sort of concur with what I was thinking. It's impossible to say without knowing more about your measurement method, though...

A little thinking shows that 990.52734 Hz is the location of a bin for all FFTs of 1024 or greater (which are the ones most commonly used) - and 991Hz is of course the closest integer frequency to that. If your signal generator is digital and has fine frequency control, I'd recommend setting it as close as possible to that number for the best FFT result when using an FFT of 1024 or greater. As you use longer and longer FFTs, 1kHz gets closer to the location of a bin, so these problems should become less. It's always better to use the correct frequency from the outset, though.

If you want to work out your own suitable frequency values to use, the sum is simply:

bin width = samplerate / FFT-length

Which is 2.69165Hz in the case of 44.1kHz and a 16k-FFT. Any multiple of this number resides exactly in an FFT bin and is suitable for use as an input frequency.

The most important point to note is that this is an artefact of the FFT measurement - NOT the DAC in question.

What exactly is your question?

Originally posted by Bernhard
My basic settings are 2048 points and a period of 25µs, that gives me a 10 kHz window.

I don't rightly know what you mean by "period", nor, in this case, "window"

Given that your FFT is 2048 points long, it will capture 2048/Fs seconds of audio (46.44ms in the case of 44.1kHz samplerate). The window of an FFT is always the length of the FFT itself, by definition, and doesn't have a frequency associated with it. The bin width of a 2048-point FFT at 44.1kHz samplerate is 44100/2048 = 21.533Hz.

46 * 21.533 is 990.5Hz (this is the closest bin to 1kHz, so is the best input freq to use if 1kHz is your ideal).
47 * 21.533 is 1012.1Hz, which is the next closest bin to 1kHz.

Either of those input frequencies is fine, and will allow you to use no specialised window. If you use 1kHz as your input frequency, you'll need to use a specialised window, and get a much degraded reading.
This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.