[ltp] ALSA setup on T30 and T40

Loic Minier linux-thinkpad@linux-thinkpad.org
Tue, 25 May 2004 11:59:01 +0200


Russell Williamson <merel@wt.net> - Sat, May 22, 2004:

> I really like the dmix plugin. With the following ~/.asoundrc, I can
> play sound via any combination of mpg321, 'aoss mpg321', xmms using
> ALSA, xmms using OSS, noatun, xine, and KDE sound effects applet all
> at the same time without any extra mixing software. (Sounds awful
> but it works.)

 I've got far more success than you, I can launch multiple esd
 simulaneously or in general multiple ALSA apps and they'll play
 simultaneously.  However, I can only have a single OSS app running.

 The worse thing happens when I try to launch an OSS app through aoss, I
 get the first noise, and then silence: the sound file is truncated.

 Strangely, running alsaplayer -o oss -d /dev/dsp1 produces no sound,
 despite this .asoundrc:

pcm.dmixer {
    type dmix
    ipc_key 1024
    slave {
        pcm "hw:0,0"
        period_time 0
        period_size 1024
        buffer_size 4086
        rate 48000
    }
    bindings {
        0 0
        1 1
    }
}

pcm.!default {
    type plug
    slave.pcm "dmixer"
}

pcm.dsp {
    type plug
    slave.pcm "dmixer"
}

pcm.dsp0 {
    type plug
    slave.pcm "dmixer"
}

pcm.dsp1 {
    type plug
    slave.pcm "dmixer"
}

ctl.dmixer {
    type hw
    card 0
}

 I am kind of lost with the various pcm.* declarations.  For example the
 !default is only used by esd if I launch "esd -d default", but "esd"
 alone opens something else (not /dev/dsp, lsof | grep dsp reports
 nothing).

 I've looked through the ALSA website, but I think the solution is in
 the source that I'll look at when I've got more time.  Any hint
 appreciated!


-- 
Loïc Minier <lool@dooz.org>