Live data from Hacker News

Fully Featured Audio DSP Firmware for the Raspberry Pi Pico

github.com

91–95 of 95 posts

Re: Fully Featured Audio DSP Firmware for the Raspberry Pi Pico

#91
post #66

Earlier quoted context omitted.

Just wondering, why? This is for carrying 96kHz frequencies in the signal?

In my personal experience as a music producer for the last 36 years, MIXING hundreds of channels benefits enormously from the available bandwidth. Think of it in the terms of graphics (anti) aliasing. If you open your canvas in 1920x1080, for example, and draw a diagonal line, your line will be jagged (aliased) to a certain extent. If you, on the other hand, start a canvas in 7680x4320 and draw the same diagonal line…

We've been using Nyquist's work and anti-aliasing filters for nearly as long as we've been using digital audio at all.

Your DAW (or whatever) may be able to show you the stairsteps of individual samples on a screen, but with a functional playback system it is never that way at all by the time things become analog again. Instead, it's always smoothed out by an anti-aliasing filter.

It works this way regardless of sampling rate. The stairsteps don't make it outside of number-land. You can run your DAW at 48KHz, 96KHz, or 192KHz, and signals below the least-common-denominator cutoff frequency will be identical on an oscilloscope -- and free of stairsteps. (Try it sometime. It's fun.)

Aliasing is a solved problem that has been solved for a long time. Your analogy about scaling and diagonal lines is actually a decent visual representation of how this stuff works, except it has already been working that way without being deliberately clever with overkill sampling rates.

Meanwhile: This Pi Pico DSP stack is structured very heavily towards being the last digital stage of a listening system. As-constructed, it's quite clearly evident that it is really not meant to be anything else. A person can certainly bend it to be other things (yay open source!), but you've probably already got a set of filters well-integrated into your existing toolchain that work superbly.

But if that's what you want, then by all means: Use it. Integer sampling rate conversions are trivial operations to get correct. To get the 96KHz that this project works with from your your 192KHz workflow, it's just a matter of throwing away half of the samples and playing back whatever remains. Any aliasing is out-of-band, and is removed by the anti-aliasing filter that is part of the digital-to-analog stage.

You can't hear it if it isn't there. :)

Re: Fully Featured Audio DSP Firmware for the Raspberry Pi Pico

#92
post #72
post #66

Earlier quoted context omitted.

Just wondering, why? This is for carrying 96kHz frequencies in the signal?

A sampling rate of 192kHz is overkill. And 192KHz exists as a sample rate in audio world because it is overkill. With a Nyquist frequency of ~96KHz, all of the arguments about whether a person can hear up to eg 22.05KHz, 24KHz, or if there's something meaningful all the way up at 48KHz, become completely and totally ameliorated. Those arguments were always such tiresome ordeals. The cost of dissolving those arguments…

If he could set it to 384kHz, he would.

Because of stairsteps he can hear or something.

Re: Fully Featured Audio DSP Firmware for the Raspberry Pi Pico

#93
post #73

Earlier quoted context omitted.

Audio systems get used for more than playing back music and film soundtracks. People use audio system at home to play electronic instruments. People also play video games. People do all kinds of stuff. Latency is an important factor in these things. Even videoconferencing and podcasting: With a microphone pointed at your face and a set of headphones used for monitoring that microphone, latency matters. (It matters mo…

Huh thanks for the info! I didn't know about any of this at all. Latency sounds like it could be an important consideration for some people.

Its an important consideration for everyone, since we all have our own tolerance levels for latency - think about it when you're on a Teams call and someone in your room starts speaking but you hear them a half second later on 'delay' ..

Latency is percievable by most people down to about 8-12ms .. lower than that and its harder to perceive, higher than that and you will get some people feeling like there are glitches in the audio ..

This is also important for musicians such as keyboard players, whose perception of their instrument is radically altered by that instruments latencies. Most modern synthesizers work very hard to get audio latency in their internal engines below 20ms ..

Re: Fully Featured Audio DSP Firmware for the Raspberry Pi Pico

#94
post #93

Earlier quoted context omitted.

Huh thanks for the info! I didn't know about any of this at all. Latency sounds like it could be an important consideration for some people.

Its an important consideration for everyone, since we all have our own tolerance levels for latency - think about it when you're on a Teams call and someone in your room starts speaking but you hear them a half second later on 'delay' .. Latency is percievable by most people down to about 8-12ms .. lower than that and its harder to perceive, higher than that and you will get some people feeling like there are glitche…

Hmm it seems like latency is an important factor for everyone, but especially serious musicians.

Re: Fully Featured Audio DSP Firmware for the Raspberry Pi Pico

#95
post #72

Earlier quoted context omitted.

A sampling rate of 192kHz is overkill. And 192KHz exists as a sample rate in audio world because it is overkill. With a Nyquist frequency of ~96KHz, all of the arguments about whether a person can hear up to eg 22.05KHz, 24KHz, or if there's something meaningful all the way up at 48KHz, become completely and totally ameliorated. Those arguments were always such tiresome ordeals. The cost of dissolving those arguments…

If he could set it to 384kHz, he would. Because of stairsteps he can hear or something.

Why stop there? HDMI supports 1536kHz audio -- plenty to capture WLW's AM broadcast at 700KHz alongside the entire spectrum below it. :)

But even here in these comments, they're not arguing that 192kHz is insufficient. I haven't seen anyone ever make that argument, actually, so from my perspective this sampling rate represents a useful amount of overkill.

The extra data is a very small price to pay for silence.

Post reply on HN