You are not logged in.

#1 2015-11-19 09:49:33

hifiboombox
Member
Registered: 2014-07-08
Posts: 5

Configuring MPD with multiple outputs

I have an Asus Xonar D1 soundcard, with an S/PDIF output and a 'Front' 3.5mm TRS output.
My headphones are connected to the 'S/PDIF' jack through an external DAC, and my speakers are connected to the 'Front' jack.

Through MPD, I'd like to have 2 separate outputs, one to my headphones, and one to my speakers.

However, with my current mpdrc, I cannot independently control  my headphones or speakers.

audio_output {
    type          "alsa"
    name          "S/PDIF"
    format        "192000:32:2"
    auto_format   "no"
    auto_channels "no"
    mixer_type    "hardware"
    mixer_device  "hw:0"
    mixer_control "IEC958"
}
audio_output {
    type          "alsa"
    name          "FRONT"
    format        "192000:32:2"
    auto_format   "no"
    auto_channels "no"
    mixer_type    "hardware"
    mixer_device  "hw:0"
    mixer_control "Front Panel"
}

Here is some relevant aplay/amixer output:

$ amixer scontrols
Simple mixer control 'Master',0
Simple mixer control 'Front Panel',0
Simple mixer control 'Line',0
Simple mixer control 'Mic',0
Simple mixer control 'Mic Boost (+20dB)',0
Simple mixer control 'Mic Source',0
Simple mixer control 'IEC958',0
Simple mixer control 'IEC958 Loopback',0
Simple mixer control 'IEC958 Validity Check',0
Simple mixer control 'Aux',0
Simple mixer control 'Analog Input Monitor',0
Simple mixer control 'DAC Filter',0
Simple mixer control 'Digital Input Monitor',0
Simple mixer control 'Stereo Upmixing',0
$ aplay -L
null
    Discard all samples (playback) or generate zero samples (capture)
pulse
    PulseAudio Sound Server
default:CARD=D1
    Xonar D1, Multichannel
    Default Audio Device
sysdefault:CARD=D1
    Xonar D1, Multichannel
    Default Audio Device
front:CARD=D1,DEV=0
    Xonar D1, Multichannel
    Front speakers
surround21:CARD=D1,DEV=0
    Xonar D1, Multichannel
    2.1 Surround output to Front and Subwoofer speakers
surround40:CARD=D1,DEV=0
    Xonar D1, Multichannel
    4.0 Surround output to Front and Rear speakers
surround41:CARD=D1,DEV=0
    Xonar D1, Multichannel
    4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=D1,DEV=0
    Xonar D1, Multichannel
    5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=D1,DEV=0
    Xonar D1, Multichannel
    5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=D1,DEV=0
    Xonar D1, Multichannel
    7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
iec958:CARD=D1,DEV=0
    Xonar D1, Multichannel
    IEC958 (S/PDIF) Digital Audio Output
hdmi:CARD=HDMI,DEV=0
    HDA ATI HDMI, HDMI 0
    HDMI Audio Output

Can anybody help me?

Last edited by hifiboombox (2015-11-19 09:58:22)

Offline

#2 2015-11-19 15:25:09

mukl
Member
From: Vienna, Austria
Registered: 2008-01-30
Posts: 55

Re: Configuring MPD with multiple outputs

What do you mean by "independently control"? The volume?

What about pulseaudio? There should be separate sinks for your outputs. If not, you can create one.

Another way is to use the asoundrc.
http://www.alsa-project.org/main/index.php/Asoundrc

I once created an asoundrc to make two virtual devices on one soundcard. The rear jack was used for systemsounds the front jack for music.

Last edited by mukl (2015-11-19 15:30:01)

Offline

#3 2015-11-19 18:29:10

hifiboombox
Member
Registered: 2014-07-08
Posts: 5

Re: Configuring MPD with multiple outputs

By independently controlled, I mean that I want to be able to choose which jack on my soundcard is playing music. That way, I can play something else through the other jack, like a YouTube video from Firefox.

That asoundrc that you had sounds like exactly what I need. Do you remember how it was configured? Or could you link me to a good resource for virtual devices?

I essentially have the opposite problem as this guy: http://unix.stackexchange.com/questions … eadphone-j

Last edited by hifiboombox (2015-11-19 18:33:33)

Offline

#4 2015-11-20 08:26:42

mukl
Member
From: Vienna, Austria
Registered: 2008-01-30
Posts: 55

Re: Configuring MPD with multiple outputs

I really don't remember the asoundrc config, I did it several years ago. But i remember it was a pita. smile But I will search my backups, when I'm home again.

If you use a DE like KDE Plasma or Gnome on this computer, I would recommend using pulseaudio. This way you can hand over audio streams on the fly via a GUI. You "just" have to create separate sinks for your jacks. Maybe this works for you:

https://wiki.archlinux.org/index.php/Pu … ont.2Frear

Offline

Board footer

Powered by FluxBB