1

I listen to a streaming radio broadcast on my Ubuntu GNOME PC for most of the day. I'd like to send its output to my desktop speakers, while continuing to send the rest of the output to my headphones.

Would it be possible to direct a single audio stream to a specific output device, while allowing all others to continue to use the default?

3

To supplement what StallionSA wrote above, you do need a second audio device, but it does not have to be a sound card in the physical sense of a card which you insert into a slot on your mainboard.

If you do a search on the web you will find many USB "sound card" devices which could be used to connect your headphones and these range from budget to some quite expensive USB DACs specifically designed for quality headphone listening.

Once you have your USB sound card plugged in (which should in most cases be plug and play to use so long as it conforms to the USB audio conventions) you then would then need to configure /etc/modprobe.d/alsa-base.conf.

to set the USB device to default ALSA sound card 0, and the other as sound card 1, and then use pavucontrol to direct the application streaming the radio station to the sound card to which the speakers are connected.

It is also possible to do via the environmental variable PULSE_SINK at the time of launching the application, eg in a Bourne shell

PULSE_SINK="alsa_output.usb-Creative_Technology_SB_X-Fi_Surround_5.1_000004it-00-S51.analog-stereo" mplayer "http://mozart.wkar.msu.edu/wkar-fm-mp3" &

The list of available sinks (Pulseaudio term for output device) can be found using

pactl list short sinks
2

From my understanding you would need an second sound card, as most sound cards only have a single DAC "digital to analog converter", which can route an audio source to multiple jacks, you need a second sound card to have a second DAC to be able to route a second audio source to a second jack.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.