For clearness' sake, and maybe to give my own ideas an order, I'll try to list what topics will be examined in this short article. Please don't assume this is everything linux has to offer us, it's more like a good start:
One gets to fully understand the exceptional flexibility of this entire system only after learning how to manage the way its different parts can interact and cooperate. This design satisfies whichever type of Audio requirement thanks to its modularity. To say it all, one of the iluminated aspects showing how well Linux Audio is growing, is this adherence to the simple rule that made Unix (and Linux) great: every application takes care of *one task*, every requirement is satisfied singularly and in a modular way.
ALSA's own task is to manage audio-relalted hardware in kernel-space, from cheap consumer sound cards to professional ones. Jack is the audio server, it allows the interaction between all the sound applications that make use of its API, LADSPA supplies the platform for audio plugin development, with several sound processors and digital effects. Finally, on top of this, Ardour is in my opinion the most successful example of how far Audio and Linux can go: A professional Digital Audio Workstation (DAW) able to transform your PC in a recording studio
This document is not proposed like a how-to or a detailed guide to compilation/installation/configuration. First of all because what would be one boring read (and write) and because the net is already full of such guides, I will limit myself to supply some links where necessary.ALSA
ALSA timidly started in 1999 with an ambitious target: to conform and standardize the Audio Layer in the linux kernel. After approximately five years the objective it has been reached, with the release of version 1 of drivers the ALSA finally integrated in linux kernel 2.6.
Audio was traditionally supported in linux through a set of drivers (OSS) absolutely does not standardized and often described as evil from the very same audio developers. There also existed the option of propietary drivers, I wonder whoever made that choice. The situation was pretty sad. Alas, even if obsoleted, OSS drivers are still used by many linuxers, and still included as a (deprecated) choice in new kernels
Do you remember the first brave distributions including ALSA drivers in their own purposedly patched kernels? The first distribution that comes to mind is SuSE, great fosterer of the plan. I recall a distribution named something like BestLinux for the first time suggesting the option to use ALSA in place of the old OSS.
My soundcard is a Yamaha OPL3SA2, not exactly the top on the market, but apart from the usual problems due to the fact of being a famous ISA "plug' n' pray" card, it has always worked decently with OSS. With decent I mean: listening to some mp3's, hearing "hello! this is Linus Torvalds and pronounce Linux ", or some most hateful login sound :) . With OSS drivers, the problems began when trying something more advanced than "cat example.wav > /dev/dsp", for the lack of common guide-lines, few advanced audio applications were available, while several applications called "sound servers" were born with the scope to satisfy in user-space the lacks of kernel-space, more on this in the paragraph dedicated to Jack.
With ALSA the things changed, it started a positive feedback carrying greater and greater interest and attracting to linux more and more audio developers who, even with good ideas, couldn't put them to reality traditionally. Making use of devfs and procfs, and sufficiently abstracting the interaction between software and hardware, ALSA has allowed to have a rational, modern and homogenous API. It does wonders with a card like mine, allowing me to shape all the parameters that OSS did not even see, the better with professional cards with 8 or more inputs and outputs, midi and eveything you may need.
ALSA allows you to choose which modules or characteristics to use or exclude from kernelspace thanks to its modular structure, it provides libraries in userspace for the applications that make use of its API , and a series of basic utilities such as: arecord, aplay, alsamixer. Another advantage for ALSA is the complete compatibility with old the OSS, in order to guarantee the usability of the obsolete audio applications, this oss-compatibility layer can be disabled too, if you decide so.
ALSA does not use /dev/dsp anymore, like already pointed out it uses devfs - now replaced by udev - virtual devices in /dev/snd/* that reflect the actual hardware found on the machine. With my opl3sa2 I will have a device for LINE IN, one for MIC IN, one for every OUTPUT channel, one for MIDI and other invisible during the normal operations. Each one of these devices has a generic identifying name reflecting its function. In this way, I can read from and write to the soundcard at the same time. This translated in less geeky terms means to record and to listen at the same time to and from the PC!