I would like to use my Raspberry Pi to save audio and play it back. Ideally I'd like to create a delay buffer so audio coming in is sampled and played back at a certain delay. It seems like the the easiest way to do this is to get a USB audio input device that has a driver for Linux. What I get to that point, though, where can I learn to write code that accesses data coming from that driver?

Basically, any USB device implementing Audio class would be good. You need to put the right settings into /etc/asound.conf file. When you plug the USB audio adapter it should be recognized by the RPI and you would be able to use a few apps that using the sound driver.

As for some code examples you can try ALSA utilities and some other apps using the ALSA audio driver (e.g. mpg123, aplay, ...)

I would like to use my Raspberry Pi to save audio and play it back. Ideally I'd like to create a delay buffer so audio coming in is sampled and played back at a certain delay. It seems like the the easiest way to do this is to get a USB audio input device that has a driver for Linux. What I get to that point, though, where can I learn to write code that accesses data coming from that driver?