Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

blueutil -p 1 returns Failed to switch bluetooth power on in 10 seconds #78

Closed
aleixsr opened this issue Apr 9, 2023 · 4 comments
Closed

Comments

@aleixsr
Copy link

aleixsr commented Apr 9, 2023

On Ventura 13.3 i got this error : "Failed to switch bluetooth power on in 10 seconds" when running "blueutil -p 1".
I need to run it after sleep because BT doesn't wake up.

Running this script works fine, but it needs sudo:

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

@toy
Copy link
Owner

toy commented Apr 10, 2023

Could you please clarify what do you mean by «BT doesn't wake up»? Was it on before sleep and is off on wake up?

@aleixsr
Copy link
Author

aleixsr commented Apr 11, 2023

Yes exactly, it was on before sleep, then I close the lid of my laptop, it sleeps and later, when I open the lid, it wakes up but bluetooth is off and I cannot enable it neither blueutil nor System Preferences > Bluetooth > Turn Bluetooth On/Off.

UPDATE: Also, having BT working finw and if I try to run "blueutil -p 0 && sleep 10 && blueutil -p 1" I got "Failed to switch bluetooth power on in 10 seconds".

Thanks for your help.

@toy
Copy link
Owner

toy commented Apr 11, 2023

Original issue feels like related to bluetooth internals, so not sure if blueutil would be able to do something. Are you able to switch power from the menu bar or preference pane after sleep? Same question for when blueutil -p 0 && sleep 10 && blueutil -p 1 fails

@aleixsr
Copy link
Author

aleixsr commented Apr 12, 2023

You're right, it is not blueutil related, I cannot turn on BT using switcher from preference pane, sorry about that.

@aleixsr aleixsr closed this as completed Apr 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants