Sunday, May 14, 2017

How I learned to stop worrying and love digital gain

Sometimes, digital sources need to have their volume raised.  This may be less true if you simply have a transport sending digital to a DAC.  But once you have fancy multi-way and multiroom systems combining equipment from many rooms, and analog sampling locked and now unlocked formats from classic drives (I don't know why, but resampling the analog outputs to 24/96 always sounds better than taking the digital stream off the device, even though it goes into a digital connection either way), you often need to do a little boosting, sometimes just to restore original recorded levels, or in the case of home made recordings from analog sources especially, to exceed them a little bit.

But once I begin cranking the digital volume control above unit gain, 0dB, which on the Tact is 93.9, I get a little worried that digital clipping might occur.  This would occur if the digital signal sent from the Tact onward to the DSP processors reaches the clipping point, which is 0dB.  Beyond that point, I didn't know what was going to happen.  Perhaps dropouts from a validity bit being set.  These dropouts could be far more annoying than typical analog clipping, even on a solid state amplifier (and the "sound" of solid state clipping has been rarely heard or correctly described...in a well designed Class AB amplifier it will not be spitting or overly harsh...just a growing soft harshness.  Anyway, not knowing the effect of digital clipping, it might even be some terrible out of band spiking, for example, of the kind that nearly fried my ribbon tweeters when connected to a 250 Amp (that was actually using the 10V RMS analog outputs of a DCX crossover, but the reason why it was outputting so much in the first place I don't remember and feared was in the digital domain).

But anyway, I didn't really know, because I had never tested it well.  And I had another related issue.  Some months ago I discovered Sonos was boosting volume levels so that "max" now had +8dB digital gain, causing premature clipping.  Perhaps this would not affect people using the analog outputs or something, I don't know, but it seemed a misfeature to me.  I took the precaution thenceforth from keeping all Sonos level at -8dB, which seemed to be the new unity gain.  Even fixed output setting seemed to have boost.  Well some time ago I wasn't sure it was still like this...volume levels were seeming softer than before.  I needed to retest.

I'm happy to say that as of today, my Sonos system passes closest to unity gain turned all-the-way up, and on the fixed setting.  It doesn't add extra boost, just the real deal...well almost.  It seems, according to my test, that a 0dB SPL signal is reduced to -1.3dB.  I'm not sure why that is, but 1.3dB of loss of dynamic range is not a huge concern, ,just a minor gripe really, but if I could have my pony I'd have full bit transparency, which I thought Sonos used to have back in the day.  I could be wrong but multiple tests showed the -1.3dB loss with Sonos "fixed" setting (I've set several back to fixed now, no need to keep fiddling to find the most transparent point) on my Behringer DEQ meter, ,and I needed to crank the Tact up to 1.3dB to reach the highest unclipped point, with clipping starting at +1.4dB but barely visible, and so on, at the output of my DAC, which I believe to be faithfully reproducing what it receives from the DEQ, and comparing that with the Triumph analysis of the WAV file.

Anyway, boosted back to normal and fixed, Sonos is now sounding good again.  That's at least two major advances in the past few days since my return from vacation, the first being un-attenuating the Sony 9000ES.

Cranking up the Tact beyond the transposed clipping point at +1.3dB, it simply clipped the voltage rise at that point, flat, pretty much like a transistor amp, with no artifacts at all.  And that continued as I drove it into "hard" clipping, it just made the wave slopes steeper, meeting a flat top at the same point, as I had speculated earlier, boosting the RMS voltage but not actually raising the peak voltage.

Through any of my DEQ units, the clipping would show the effect of the EQ on the waveform as it clipped, looking a it more curvey for example, but still not too bad at all.

Now, sending an unclipped signal at 0dB into a DEQ unit, and then attempting to clip it within the DSP program had a different effect.  Clipping through the DEQ resulted in a compressed output that showed no sign of clipping, just no increase in size.  I'm a bit worried about this, perhaps on real music it would cause peculiar effects more annoying than the slight harshness of peak clipping.  Or perhaps not.  But either way it didn't look any more scary and probably less scary than analog clipping.

So while you can argue that cranking up the digital volume should not be much necessary, better to have the source material reaching peak 0dB or close to it to preserve resolution.  But when you need to crank up the volume, doing so with digital gain isn't any more dangerous than doing it in the analog domain, and probably safer, with regards to level changes that may later cause clipping.

This adds to the case for mapping the output of a DAC driving the amplfier to have exactly the output required to drive that amplifier to clipping, or slightly more, rather than 6dB more or so.  The added affects of digital and analog clipping around the same point should not be bad, if very rarely reached. As I have previously argued, this preserves the dynamic range and resolution better at every level.

Similarly, I've now concluded that adding boost in the DEQ's, all of the DEQ's, not just to compensate but to create more digital gain, is not a good idea, as it shortens the actual digital mapping space just like having a DAC with too much output.  The best gain setting on any digital device is 0dB or as close to it as possible, to preserve dynamic range and resolution.

Pictures later.



No comments:

Post a Comment