meta data for this page
This is an old revision of the document!
Alsa
asound.conf
By default sound is processed through dmix plugin which handles rate and channels conversion.
Plugin: hw
This plugin communicates directly with the ALSA kernel driver. It is a raw communication without any conversions.
To override “default” pcm device and route outputdirectly into hardware:
pcm.!default {
    type hw
    card 0
    format S16_LE
}
With settings above, there is no possiblity to play mono sound (channel=1), when there is stereo audio device.
Plguin: plug
Is a plugin responsible for rate and format conversion.
pcm.!default {
    type plug
    slave {
        pcm "hw:0,0"
        format S16_LE
    }
}
There might be problems with some programs though. Some applications always try to open a control device with the same name as the pcm device they are given, so you may also need to create a dummy control device with the same name:
ctl.!default {
    type hw
    card 0
}