-
Star
(368)
You must be signed in to star a gist -
Fork
(59)
You must be signed in to fork a gist
-
-
Save nicolasembleton/afc19940da26716f8e90 to your computer and use it in GitHub Desktop.
#!/bin/bash | |
sudo kextunload -b com.apple.iokit.BroadcomBluetoothHostControllerUSBTransport | |
sudo kextload -b com.apple.iokit.BroadcomBluetoothHostControllerUSBTransport |
#!/usr/bin/env bash pgrep audio | xargs sudo kill pgrep bluetooth | xargs sudo kill sudo launchctl list | grep -i blue | awk '{ print $3 }' | xargs sudo launchctl stop sudo launchctl list | grep -i blue | awk '{ print $3 }' | xargs sudo launchctl start sudo launchctl list | grep -i audio | awk '{ print $3 }' | xargs sudo launchctl stop sudo launchctl list | grep -i audio | awk '{ print $3 }' | xargs sudo launchctl startI use this script and fixed my problem :D
Works for BigSur. Thanks!
#!/usr/bin/env bash
pgrep audio | xargs sudo kill
pgrep bluetooth | xargs sudo kill
sudo launchctl list | grep -i blue | awk '{ print $3 }' | xargs sudo launchctl stop
sudo launchctl list | grep -i blue | awk '{ print $3 }' | xargs sudo launchctl start
sudo launchctl list | grep -i audio | awk '{ print $3 }' | xargs sudo launchctl stop
sudo launchctl list | grep -i audio | awk '{ print $3 }' | xargs sudo launchctl start
After months of searching and trying stuff, this seems to work on Catalina OS (10.15.7) on a MacBook Pro 8,1. As soon as I ran the script, the bluetooth started working again. No rebooting or resetting the SMC module needed so far. The bluetooth conection will still drop out after a while, but the script is definitely more convenient than the rebooting every 30 minutes like previously.
Thanks a bunch, @agate ! Do you have any idea as to why this works and if there is a more permanent fix?
Cheers.
@AnaatGitHub so I just violently killed all the Bluetooth and Audio related processes. I guess MacOS is smart enough to restart all those background processes if you are trying to use them later. You know "reboot fixes almost 99 percent problem" lol.
BTW, I am not sure if there is any other way / app for doing such thing.
@paulbargaoanu you are welcome. I am glad it works :D