Ubuntu – Switch between headphone and speaker automatically

17.04outputsoundspeakers

I'am using ubuntu 17.04.

When I connect my headphones I need to manually switch my sound output in the settings from speakers to headphones. After removing my headphones I need to manually switch back to the speaker.

How can this be done automatically?

Best Answer

  • I don't know that there is A BEST solution to this, it's up to personal preference.

    What I love to do is have my usb headphone and 5.1 surround sound system plugged in at the same time.

    To switch from one to the other, say sound-system to headphones, I hit the power button on my sound system to trun it off and scroll the volume knob on my usb headset to turn it on (system volume is on 70% so 100% on the headset is a fine tuned fit).

    Guide.

    Note : once "Add virtual output device for simultaneous output on all sound cards" is enabled, reboot then continue the rest of the steps.