PWM audio is sorta like DSD?

This is more of a theory/terminology question. I’ve gotten myself quite confused trying to compare the principles of PWM audio output with the Arduino to the principles behind “Direct Stream Digital” (DSD: This has nothing to do with audio quality or the debate over whether DSD is better than pulse-code modulation (PCM); I’m just trying to get the terminology straight.

When PWM is used with modified timer settings for audio output (examples linked below), is it using the same principles as DSD (Direct Stream Digital) audio?

From what I gather, DSD is “stored as delta-sigma modulated digital audio”, delta-sigma modulation uses pulse-density modulation(PDM), and PWM is a special case of PDM. So, is it accurate to say that these PWM audio techniques are like those used in DSD? Obviously, DSD is a trademark, not a technique, but my question is, are the same principles being employed? How are they different?

In every case I know of, the audio data is stored as 8-bit, PCM-style values in the Arduino. (In fact, the second example linked below calls it PCM for this reason.) However, the output itself is 1-bit with a much higher sample rate. So, in effect, PWM is used to convert each 8-bit value into 256 1-bit samples. Is this output like DSD? How is it different?

Further, less important questions: If PWM output is indeed like DSD, would it be possible to store audio data in DSD form in the Arduino? As an array of bits or something, rather than an array of bytes? Would DSD input to the Arduino be possible? If not, is the fast data rate the only reason it isn’t?

Arduino PWM audio examples: (discussion of the principles)

Thanks in advance for any info/clarification you can give.

Not sure if this helps or not.

Using Roman Black's Btc Sound encoder with arduion:,50017.0.html

Also, I did a small article on generating multiple pwm sounds with timers. I managed to get 6 voices, each on its own pwm output pin, with a regular arduino. I posted here at the Audio forum area.


That is helpful, for ideas at least.

I think I'm beginning to understand the difference between PWM and DSD-style 1-bit audio. For a middle value like 127, PWM would be high for 127 samples, then down for 127 samples, while DSD would flip back and forth from HIGH to LOW 127 times during one PWM cycle. Of course, doing the same thing during that whole cycle loses some of the benefits of the higher sample rate of DSD. Obviously, there's no way to make the Arduino's PWM behave that way. But, maybe something like that be accomplished by very quickly changing a digital output (perhaps helped out with direct port manipulation or digitalWriteFast:,46896.0.html). I'll give it a shot soon, for curiosity more than anything.