Mixer control with multimedia keys und multiple soundcards in XFCE4 on debian

Just struggled over a pretty weird phenomenon. Nowadays multimedia-keys in current Linux distributions usually work flawlessly. When you type the "Louder"-key you usually see a little on-screen display that shows you that you increased your volume. However, when having multiple soundcards and running the XFCE4 desktop it always uses the first mixer-element of the first soundcard available. After searching around a bit, I often read the solution to use System-Preferences-Sound (which is basically the sound setting in gnome-control-panel) to select a default soundcard - it would be automatically used from the multimedia keys -- wrong. Does not work in XFCE4. After some more frustrating search (probably should use this one for our search experiment with search-logger), I discovered that xfce4-soundd is responsible for these actions. This one uses settings from xfce4-mixer. However, selecting a soundcard in xfce4-mixer still doesn't do the job.

Ok, how to solve this: If you use pulseaudio, just select in xfce4-mixer the Playback device of your soundcard you want to apply the multimedia-keys to. Then fire up xfce4-settings-editor, go to xfce4-mixer and take a look at active-card and sound-card. They were different in my case. Sound-card hat the entry PlaybackInternalAudioAnalogStereoPulseAudioMixer, active-card the name of my first sound cards. I copied PlaybackInternalAudioAnalogStereoPulseAudioMixer to active-card, logged out and in again, and now my multimedia keys control the soundcard selected in pulseaudio for output.

Sound in Linux has still a touch of magic -- but I think we are getting closer ;-)

Comments