TechTalk: External DACs
We sometimes here customers want to “upgrade” from a HiFiBerry DAC to an external DAC. Decoupling the DAC from all the digital noise on the Raspberry Pi seems to be a good idea – right? It often isn’t! To understand why this isn’t the case, let’s understand what happens with the audio data on music playback.
First, the software on the Pi reads the data from the SD card, a server or a streaming service and decodes them. The result are PCM samples – for the standard CD format 44100 of these per second, each with 2 channels of 16bit. High-res audio can use more samples per second and/or more bits/sample. These audio data are now in the memory of your Pi. What happens now?
Let’s start with a HiFiBerry DAC that’s connected directly to the Pi: The Pi’s processor includes a specific hardware that deals with this data and transfers it using a protocol called I2S. As a user you should not have to think about this at all. However, for this TechTalk we’re looking into a bit more details. As the audio data is at least 16 bit/sample and there are not 16 wires running to the DAC, the Pi has to convert this into a serial format, that looks like this:
This is fully handled in hardware in the Pi’s processor. The player software just sends a bunch of data from time to time and the Pi’s hardware deals with the transmission. That’s the reason why audio playback works well even if your Pi is running under heavy load.
The DAC chip on the HiFiBerry DAC now uses these 3 signals and converts the data to an analog signal. That’s simply the shortest path from the application to an analog output signal.
Using the HiFiBerry Digi, the process is basically the same. However, there is no DAC chip, but an SPDIF transmitter chip. Instead of converting the signal to an analogue audio output, the three I2S signals (SCK, WS, SD) are multiplexed (basically mixed together) into one signal. On the other side – your external DAC, the process is being reversed. As this is a fully digital transmission it should be 100% the same – right? Almost. The data itself should be exactly the same, but depending on the receiver, the timing of the clock signals might be slightly off. A perfect external DAC should re-create the signal exactly as it was. However, not every DAC does this right. If you hear differences between different digital audio sources with your DAC and some sound better than others with exactly the same data, that’s a sign that your DAC doesn’t do the clock recovery exactly right.
USB sound cards
A similar thing happens with USB DACs. However, there is no serialisation to I2S in the beginning. The data is packed into data packets which are being sent to your DAC. Now the DAC has to create these clock signals. You might see the same issues here. Some people use special USB isolators or USB clock regenerators to improve the performance. If these really make a difference that’s a sign that the DAC itself doesn’t do some thing right.
How bad is it?
In our experience, most external DAC do a good job. They don’t have to sound worse than a HAT. However, there’s also no reason to think they sound better just because they are external. Can an external $2000 DAC sound better than a $40 HiFiBerry DAC? Sure! And hopefully it does – otherwise it would not be a good idea to spend $2k. However, the devil’s in the details. We regularly hear reports from users experimenting with different digital audio sources because they sound differently. That should not happen!
Do we know what sounds best in your environment? Definitely not. If you want to experiment with different devices – feel free to do so. Just don’t expect that an external DAC will simply do things better. It might, but there’s a good chance that it does not.
January 28, 2021