Hacker News new | ask | show | jobs
by adamzegelin 970 days ago
Probably do-able using Pipewire/Pulseaudio.

I just tried, and I'm able to pair both my Macbook Pro and iPhone to my Linux desktop PC. The PC has Kensington Bluetooth USB dongle. Both the MBP and iPhone can simultaneously play audio over Bluetooth and I can route the incoming audio to a pair of wired headphones. The volume of each stream is independently adjustable via `pavucontrol`.

I also tried pairing a bluetooth headset, but the audio was choppy. Maybe too much bandwidth for 3 devices streaming audio at once? Maybe another dongle would work?

Note that at one point I was experimenting with receiving BT audio on my PC. I can't remember the exact set of configuration changes needed to make this work (if any -- it might've worked out of the box). But the stack is BlueZ + Pipewire on Archlinux.

Pipewire (and Pulse) have a lot of modules and config knobs. Might be possible to get auto-switch working too. They also expose a D-Bus interface, so control from some sort of e.g. Python webapp from your phone is likely.

2 comments

Definitely possible, and I've done a similar proof of concept using PipeWire with "Wireplumber" as the GUI to map the required inputs/outputs to a wired headset.

The problem was that I had no clue where to even begin to make this setup persistent so I could eventually put it all on a GUI-less RPi, so I gave up.

> I also tried pairing a bluetooth headset, but the audio was choppy.

Try reconnecting it. I have the same problem with my headset sometimes and reconnecting fixes it. My best guess is the implementation of the two Bluetooth modules don't play nice with each other. I have no troubles connecting to a different pc.