[pulseaudio-discuss] Device fallback priority
Daniel
windseeker at gmx.de
Sun Apr 12 14:30:18 UTC 2020
Am So., 12. Apr. 2020 um 16:24 Uhr schrieb Tanu Kaskinen <tanuk at iki.fi>:
>
> On Sat, 2020-04-11 at 22:29 +0200, Daniel wrote:
> > Hello,
> >
> > I have 2 alsa devices in my system, card 0 is my Nvidia graphics card
> > for HDMI Audio output, card 1 is my internal onboard audio. I prefer
> > the HDMI Audio via my Nvidia card and setting this as default device
> > works just fine.
> >
> > When I now add another audio device like via USB or Bluetooth, its
> > sink becomes default, and this is quite what I want, so this is fine.
> > But when I now disconnect this device again, the new default sink
> > always is my internal audio instead of the HDMI audio.
> >
> > How can I get the system to fall back to my HDMI Audio after the
> > active sink gets unavailable? Can I set priorities manually in
> > default.pa or similar?
> >
> > The modules module-default-device-restore, module-device-restore,
> > module-stream-restore and module-card-restore are loaded. If one of
> > these is supposed to do this job, does that need some manual
> > configuration? If yes, how?
> >
> > I'm running Ubuntu 19.10 64-bit. I already deleted ~.config/pulse and
> > restarted pulseaudio to make sure there are no unwanted settings in my
> > pulse db files. The file .config/pulse/[id]-default-sink correctly
> > contains the HDMI sink in the format of the output below.
> >
> > $ pactl info
> > Server String: /run/user/1000/pulse/native
> > Library Protocol Version: 33
> > Server Protocol Version: 33
> > Is Local: yes
> > Client Index: 8
> > Tile Size: 65472
> > User Name: daniel
> > Host Name: windseeker
> > Server Name: pulseaudio
> > Server Version: 13.0
> > Default Sample Specification: s16le 2ch 44100Hz
> > Default Channel Map: front-left,front-right
> > Default Sink: alsa_output.pci-0000_01_00.1.hdmi-stereo
> > Default Source: alsa_output.pci-0000_01_00.1.hdmi-stereo.monitor
> > Cookie: b87b:c3cd
> >
> > $ pactl list sinks short
> > 1 alsa_output.pci-0000_00_1b.0.analog-stereo
> > module-alsa-card.c s16le 2ch 44100Hz IDLE
> > 4 alsa_output.pci-0000_01_00.1.hdmi-stereo
> > module-alsa-card.c s16le 2ch 44100Hz IDLE
>
> If you never use the internal audio, you can switch the card profile to
> "off" with pavucontrol or pactl.
Thank you, Tanu. This would be a quick fix indeed. But actually I have
one application that should use it. But maybe my workaround could be
that I write a wrapper around this application that uses pactl
set-card-profile to switch this card on before and off afterwards. So
thanks for the hint.
Regards,
Daniel
More information about the pulseaudio-discuss
mailing list