Understanding oversampling

Status
This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.
If someone used the term "4x oversampling", are they referring to figure 2, 3 or 4? (or something else entirely?)
 

Attachments

  • Screenshot_2020-10-25_22-37-59.png
    Screenshot_2020-10-25_22-37-59.png
    9.9 KB · Views: 211
  • Screenshot_2020-10-25_22-38-09.png
    Screenshot_2020-10-25_22-38-09.png
    12.1 KB · Views: 233
  • Screenshot_2020-10-25_22-38-21.png
    Screenshot_2020-10-25_22-38-21.png
    11.2 KB · Views: 222
  • Screenshot_2020-10-25_22-38-34.png
    Screenshot_2020-10-25_22-38-34.png
    13.2 KB · Views: 223
Figure 3 shows the insertion of the necessary extra samples for 4x oversampling, but they are only zero value place holder samples as yet. Three new samples values need be calculated for each originally input sample. As shown in the figure.

Figure 4 shows what happens to the zero value samples after the entire sample string of figure 3, has been passed through a digital reconstruction filter. Typically, a 'brick wall' low-pass.
 
Member
Joined 2009
Paid Member
The last three figures are all examples of oversampling. Naturally you get better performance if you interpolate between the two original samples as shown in the last figure. What you've shown is a simple linear interpolation. You can get fancier if you use more of the original samples in your interpolation and use some sort of polynomial fit.

Tom
 
Now I'm curious if anyone has performed some of the oversampling in the analog domain, rather than entirely digital.

i.e. insert zeros, then actually run them through the DAC, and use the analog reconstruction filter to low pass the result. I suppose this might have disadvantages. For one, the amplitude of the DAC output would be lower (2x oversample would be half the amplitude, as the DAC is now outputting zero current half the time), and I'd imagine that shutting the current off entirely every other sample might be the worst-case analog performance of the chip, and might exacerbate lead inductances, etc?
 
Member
Joined 2017
Paid Member
Fig.3(zero insertion) is the only answer to reproduce the original signal. Fig.2 isn't. Fig.3 and Fig.4 are the same frequency spectrum if Fig.4 is processed by a perfect digital filter. It's possible to use 4fs when you sample the data. But if your target has 0.5fs bandwidth, you have meaningless data(redundancy). So, you can replace the redundant date with zero like Fig.3. Instead of memorizing four times data, you can use fs. Zero insertion at sampling means data compression; now, you have 1/4 data. You can define oversampling as the reconstruct process of deleted data at sampling.
 
If by 'analog performance' you mean SQ then in the days before I developed passive filters to put after my DACs, I found slower sounded better in that it had more dynamics. With a filter though I'm hard pressed to hear any loss going from NOS to 2XOS - in fact due to the reduced images 2XOS does sound slightly cleaner. Running 2XOS also allows me to delete the droop correction EQ stage which has to be a good thing. This is all using a 30-year old multibit DAC chip.
 
So, now for the new to audio digital world,
A modern dac, given a CD as the source file, if DAC set to some higher bit rate, windows is set to a higher rate, is it doing the oversampling, or is that the responsibility of the host (PC) application to do so before sending? Or is nothing being done and the direct 44.1 is being converted?

Back in the CD player days, it was all done in the player DAC.
 
Windows can certainly do SRC, and do so on the fly without telling you. Unfortunately, Windows does it with rather poor sound quality. Thus, ASIO drivers were invented so that Windows can be persuaded not to mess with the audio (at least if Windows is configured properly, a topic in itself).

Some people are upsampling and or converting PCM to DSD in computers before sending the audio out to a dac. Probably the best software for that is HQ Player, but there are other choices too ranging from free to somewhat expensive. Sound quality can be very high with the right software and with a powerful enough PC to do all the number crunching in real time.

What a dac does with upsampled digital audio from a computer depends on how the dac is designed and configured. The dac may do further upsampling of PCM or not, but probably will by default.
 
Ah, good info. Storage is cheap, maybe I should process my files in situ.

The configured correctly does seem to be quite an issue. I have found some information, but alas, mostly comments I don't know what I am doing. Rather obvious as I am asking after all!

Of course, there is a lot of argument about filter design and if it has any effect.
 
Okay, configuring windows for ASIO drivers. First you need at least two sound devices, basically one dac you want to use for playing music, and another one you are willing to let Windows mess with.

Hold down the Windows key and hit R. A run dialog should open wherein you can type mmsys.cpl which should take you to the sound device configuration control panel object. There are other ways to get to the same place, but this one should work.

First you need to get rid of any green check marks in the rectangular box for the dac you want to use. Right click on the dac you don't want to use, and assign it to be default sound device and default communications device. (Please see the attached screenshot below.) Then double clicking on the dac you do want to use should open a properties window. Go to the level tab and turn it up all the way (same think as turning up the volume for that dac from the desktop widget when it is the default sound device (or maybe whenever it is playing, not sure). Leave it all the way up as far as Windows is concerned.

Then use an app such as Foobar2000 to play all music files. Download and install the ASIO component for it then go into its configuration and select the ASIO driver for the dac you want to use for playing music. Then you can select some music and hit play. Windows should be leaving your audio alone. Looking in the sound control panel applet window you should not see the VU meter for the dac you are using moving around. That should only be active when audio is passing through Windows Sound Engine, something we are using ASIO to avoid.

For best sound quality from your dac, it is best not to use a software volume control except that it may help to audibly lower distortion if the volume fader in your ASIO program (foobar in this example) is turned down to a few dB below maximum. That's because dacs often have a bit higher distortion when operating too close to 0dBFS. Usually -3dBFS to maybe -6dBFS is enough attenuation to minimize any distortion.

After that its best to control volume using a hardware volume control inside the dac chip or using hardware volume control after the analog output of the dac. Some info from ESS is applicable to many modern dacs with internal hardware volume controls: http://www.esstech.com/files/3014/4095/4308/digital-vs-analog-volume-control.pdf

I may have forgotten to mention something or other. If so and I remember later I will post a follow up. Other than that please if any questions.
 

Attachments

  • WinSoundConfig.jpg
    WinSoundConfig.jpg
    67.1 KB · Views: 81
Much thanks. A task for the morning, or will be when my new DAC gets here. Tracking said it was still in Ca. My current one does not support it.

I will download foobar again. I don't remember what I did not like about it but went Windows Media Player for the UI logic.

If Microsoft would jet off the feature adding bandwagon and just support normal things...

Convinced to use my preamp volume control. I did discover that on the E-30, I had to reduce it's output level by 15dB to get it's distortion down. Does not make sense as that was not needed on my old MUSE or my Focusrite.
 
Status
This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.