PD and jack
I wanted pd, mpd, and libao-using programs all to be able to play sound on an EeePc 900A running Ubuntu 11.04.
pulseaudio wasn't working (the device name in pd was garbage bytes, and it would always fail after about a day). Plain alsa wasn't working, since I couldn't get multiple clients playing at once even with dmix. I finally got jack to work, which is pd's preferred solution anyway. Here are the steps that I think were needed:
- When you install jackd2, agree to the realtime priority stuff. Run "sudo dpkg-reconfigure -p high jackd2" if you need to be asked that question again. (original forum post)
- Make sure your user is in the 'audio' group.
- Write this to ~/.asoundrc (alsa docs)
pcm.jackplug {
type plug
slave { pcm "jack" }
}
pcm.jack {
type jack
playback_ports {
0 alsa_pcm:playback_1
1 alsa_pcm:playback_2
}
capture_ports {
0 alsa_pcm:capture_1
1 alsa_pcm:capture_2
}
}
# not necessary if all clients can set their device to 'jackplug'
pcm.!default {
type plug
slave { pcm "jack" }
}
- Put the lines "default_driver=alsa" and "dev=jackplug" in /etc/libao.conf (libao docs)
- Arrange for "jackd -d alsa" to be running
- Give mpd.conf this pretty output block:
audio_output {
type "jack"
name "My jack Device"
}
- Test with "aplay -Djackplug some.wav" and "aplay some.wav" (the default device setting)
- Run qjackctl to see what's going on. It's like pavucontrol, for jack. You don't need to press its play button. Open the 'Connect' window to see current clients and connections.
- Run pdextended with -nrt -jack
- New comment
Atom feed of this blog