2

I've got two MBPs and a pair of bluetooth headphones that can only be connected to two devices at once.

I need to use this pair on both MBPs and my phone but only on one MBP at a time (usually, I can manually disconnect them from my phone in the rare event that I need to use them on both at the same time).
Additionally, the headphones are buggy/crappy and play an annoying ringing noise when they lose connection to a device AFAICT. I want to avoid this at all costs.
When I walk away from an MBP, I close its lid. I would then like it to automatically disconnect any bluetooth audio device its connected to.

I wouldn't mind having to connect to the headphones manually on the MBP I want to use them on but disconnecting manually is a no-go.

This thread is a duplicate but for an older macOS version (none of the solutions work in Big Sur).

I'm aware that you could toggle bluetooth off completely but that's the nuclear "solution".

3 Answers 3

2

There used to be an option in System Preferences to toggle Allow Bluetooth devices to wake this computer that might have solved your problem.

It looks like Apple have removed this in MacOS Monterey (12.2.1) for some reason.

The solution from this post on MacRumors solved the issue for me on my M1 MacBook so my headphones actually disconnected when I closed the lid:

brew install sleepwatcher blueutil
echo "$(which blueutil) -p 0" > ~/.sleep
echo "$(which blueutil) -p 1" > ~/.wakeup
chmod 755 ~/.sleep ~/.wakeup
brew services restart sleepwatcher

This will disable Bluetooth when your MacBook goes to sleep, and enable it again when it wakes.

If you don't have brew, the installation instructions can be found at https://brew.sh

0

You could use Automator / Apple Script to unpair this bluetooth device when the Mac goes to sleep.

Here are two links from previous answer of this forum that could help you get started:

0

I've landed on bluesnooze as an incomplete solution. It does not disconnect individual devices (which I'd prefer) but disables Bluetooth entirely on sleep. That works for me but might not work for others who might use Bluetooth keyboards and the like.

I'm sure there are other such tools but this one does what it's supposed to do and is FOSS.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .