Sound does not automatically switch to HDMI when connected

Bug #1707611 reported by David
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
pulseaudio (Ubuntu)
Confirmed
Low
Unassigned

Bug Description

When connecting a HDMI cable or other audio device, the user must manually click on the "sound volume" in the top-right and switch to the newly connected device.

Example: you connect a HDMI cable to the television, but then you must manually choose the HDMI sound option; it does not get selected automatically.

Often times e.g. when the HDMI cable is disconnected, the user must then manually click on the "speakers" or "line out" setting - EVEN IF IT'S ALREADY SELECTED, it must be clicked on again for the sound to work through the computer's speakers.

Tags: xenial
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Please run:

  apport-collect 1707611

to tell us more information about your software version(s). And to avoid this extra step in future you might want to log future bugs using the command:

  ubuntu-bug pulseaudio

Changed in pulseaudio (Ubuntu):
status: New → Incomplete
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Oh I forgot; according to bug 1707487 you are using Ubuntu 16.04. So you are missing the fix for bug 1702794. And this becomes a duplicate of bug 1702794.

Revision history for this message
David (dave400) wrote :

I have all the updates installed, but still the same problem. Is the fix downloaded separately?

"And to avoid this extra step in future you might want to log future bugs using the command:

  ubuntu-bug pulseaudio"

Sorry, I'm not familiar with writing bug reports.

Revision history for this message
David (dave400) wrote :

Tried running apport-collect 1707611, then got this message:

You are not the reporter or subscriber of this problem report, or the report is a duplicate or already closed.

Please create a new report using "apport-bug".

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

The fix only exists in Ubuntu 17.10 right now. Since it's a "feature" more than a bugfix (according to PulseAudio developers) it might not get backported to 16.04 at all.

If you are committed though, and have some basic Unix skills, then you can apply the fix from bug 1702794 on your own system. Just edit a config file.

Revision history for this message
David (dave400) wrote :

I tried the image of 17.10 (checked its sha256sum after download, it matched) and tested the 17.10 live USB using "test disc for defects" and no errors found.

I connected the HDMI cable to the TV, but I still had to manually switch the sound from the laptop speakers to the HDMI output.

This bug appears NOT to be fixed.

Thanks again for your time and your help, it's genuinely appreciated. :)

I am happy to try other suggestions.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

The output is selected on "connection". So maybe try not plugging in HDMI until after you have logged in.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

I am now also reminded of this "feature", which was a patch in 16.04 and seems to be an upstreamed feature in 17.10:

https://git.launchpad.net/~ubuntu-audio-dev/pulseaudio/tree/debian/patches/0100-switch-on-port-available-Switch-from-HDMI-to-analog-.patch?h=ubuntu-xenial

Not sure if it's related. That module "switch-on-port-available" is definitely one that Ubuntu uses but is not mentioned in the documentation:

https://www.freedesktop.org/wiki/Software/PulseAudio/Documentation/User/Modules/

So I'm not yet sure what it's meant to do.

Revision history for this message
David (dave400) wrote :

I used a "live" version of 17.10

Please find out if those fixes can be included in Ubuntu - I'm willing to test them. If these fixes work, please ask to have them backported to 16.04, because it's a LTS release and I already have 16.04 installed on 4 computers. It is also said that LTS versions offer better stability etc.

Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for pulseaudio (Ubuntu) because there has been no activity for 60 days.]

Changed in pulseaudio (Ubuntu):
status: Incomplete → Expired
summary: - Sound does not automatically play on new audio device
+ Sound does not automatically switch to HDMI when connected
Changed in pulseaudio (Ubuntu):
status: Expired → New
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in pulseaudio (Ubuntu):
status: New → Confirmed
tags: added: xenial
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

I think this is fixed in recent releases. Please confirm or just let the bug expire...

Changed in pulseaudio (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
David (dave400) wrote :

I tried it on the live session USB 3.0, Ubuntu 19.10 (I checked the disk for defects: no errors found). I still had to manually enable the sound over HDMI for the TV.

tags: added: eoan
Changed in pulseaudio (Ubuntu):
status: Incomplete → Confirmed
importance: Undecided → Low
tags: removed: eoan
Revision history for this message
Marius Gedminas (mgedmin) wrote :

My laptop with Ubuntu 20.10 automatically switches to the HDMI output when I plug in my monitor (via a USB C cable connected to a dock station connected to the monitor via a HDMI cable).

And then, a second later, it switches to the USB dock's audio output (which has nothing plugged in), but that's a different bug.

Incidentally, module-switch-on-connect in PulseAudio 14 (and also Ubuntu 20.10's 13.99.2) has a blacklist of sink names that should not be switched to. The default value of this blacklist is a regexp matching "hdmi". The blacklist doesn't appear to work (which is also a different bug).
If it does start to work at some point, you may have to edit /etc/pulse/default.pa and change

    load-module module-switch-on-connect

to say

    load-module module-switch-on-connect blacklist=""

if you want HDMI outputs to be switched to.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.