jrouleau / bluetooth-autoconnect

A linux command line tool to automatically connect to all paired and trusted bluetooth devices.
MIT License
212 stars 42 forks source link

re-connect not working #15

Closed suuuehgi closed 1 year ago

suuuehgi commented 1 year ago

Hi,

it seems to connect fine the first time but if I switch the bluetooth device off and on again, it is not being picked up by the script anymore.

Nothing appearing on bluetooth-autoconnect -v -d.

It's stuck in GLib.MainLoop() without doing anything.

jrouleau commented 1 year ago

Please see this issue: https://github.com/jrouleau/bluetooth-autoconnect/issues/4

This script makes connection attempts when in daemon mode and a bluez adapter is powered on (e.g. bluetoothctl power on) or as a one-off via bluetooth-autoconnect (or by sending SIGHUP to bluetooth-autoconnect -d). It does not detect other devices when they are powered on or brought in from out of range. It is generally up to each device to announce itself when powered on. If you aren't concerned about battery life, you could configure a cron job or similar to continually probe.