2

PulseAudio usually does a pretty good job of determining what ALSA devices are available and setting them up automatically. When it doesn't, I'm not clear how this seemingly automatic linkage occurs. Is it a push where ALSA tells PulseAudio about the devices or a pull where PulseAudio determines from the ALSA configuration? Let's say you've got 3 audio 'cards': A, B and C. aplay -l shows all three (assume all three are working as expected via aplay) but pacmd list-cards only shows A and B. If you only wanted PulseAudio to use B and C, how would you get PulseAudio to remove A and add C? I assume this would be done via pacmd and/or changing PA's startup configuration files but I'm not clear as to how exactly to do this.

  • Without looking up details: Pulseaudio executes a startup script, which calls modules to either include all ALSA hardware (default), or specific ALSA cards (you need to modify the script accordingly, and use a different module). – dirkt Oct 8 '18 at 14:59
3
+50

I think that modules are responsible for adding devices. E.g. there is one called module-udev-detect, and if I do pacmd list-cards in my system, I see module-udev-detect.discovered = "1" in two out of the three. The third one is a bluetooth device, so I guess that one comes from the bluez5 module.

Looking at the web a bit, you can make pulseaudio ignore a device coming from udev by setting ENV{PULSE_IGNORE}="1" in a udev rule. See

I guess that for bluetooth you'd have to fiddle with bluez, to ignore the device.

As to why a device can get ignored, that can be because it was locked (alsa devices can only be open once) when pulseaudio tried to open it.

Edit from @blihp:

To force PulseAudio to attempt to use an audio device, add an entry to /etc/pulse/default.pa:

load-module module-alsa-sink device=plughw:<card#>,<device#>

(replace <card#>,<device#> with the specific hardware for your system such as 0,1)

  • If you accept my minor edits (fixed typo and added final bit regarding forcing PulseAudio to use device), I think you've got it. Thanks... that gave me the nudge in the right direction I needed. – blihp Oct 14 '18 at 14:17
  • @blihp done . . . – V13 Oct 14 '18 at 14:35

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.