Package Details: bluetooth-autoconnect 1.1-3

Git Clone URL: https://aur.archlinux.org/bluetooth-autoconnect.git (read-only, click to copy)
Package Base: bluetooth-autoconnect
Description: A service to automatically connect to all paired and trusted bluetooth devices
Upstream URL: https://github.com/jrouleau/bluetooth-autoconnect
Keywords: autoconnect bluetooth bluez
Licenses: MIT
Submitter: jrouleau
Maintainer: jrouleau
Last Packager: jrouleau
Votes: 3
Popularity: 0.21
First Submitted: 2019-03-24 04:10
Last Updated: 2019-06-24 02:43

Dependencies (5)

Required by (0)

Sources (1)

Pinned Comments

jrouleau commented on 2019-07-31 14:21

For all bluetooth devices (keyboards, printers, etc.), it is recommended to enable the main service with systemctl enable bluetooth-autoconnect run as root.

For bluetooth audio devices (headsets, speakers) when using pulseaudio, it is recommended to ALSO enable the helper service with systemctl --user enable pulseaudio-bluetooth-autoconnect run as your user, NOT root.

=====

Devices must be paired and trusted to attempt autoconnecting. See https://wiki.archlinux.org/index.php/Bluetooth#Pairing for more information on pairing

Latest Comments

jrouleau commented on 2019-07-31 14:21

For all bluetooth devices (keyboards, printers, etc.), it is recommended to enable the main service with systemctl enable bluetooth-autoconnect run as root.

For bluetooth audio devices (headsets, speakers) when using pulseaudio, it is recommended to ALSO enable the helper service with systemctl --user enable pulseaudio-bluetooth-autoconnect run as your user, NOT root.

=====

Devices must be paired and trusted to attempt autoconnecting. See https://wiki.archlinux.org/index.php/Bluetooth#Pairing for more information on pairing

jrouleau commented on 2019-07-31 14:18

@GrievousMa

With pulseaudio, you also need to enable another service with systemctl --user enable pulseaudio-bluetooth-autoconnect run as your user, NOT root.

Pulseaudio runs as your user (by default) and therefore doesn't start until after you login (whereas bluez is started when the system boots). You can't connect to bluetooth audio devices until after pulseaudio is running, so the initial attempt with the bluetooth-autoconnect (before logging in) doesn't work.

It is safer to trigger a connection attempt with the pulseaudio-bluetooth-autoconnect service because it is guaranteed to be run after pulseaudio starts. The xfce autostart option MAY trigger before pulseaudio finishes loading which would cause it to fail.

GrievousMa commented on 2019-07-31 13:58

@jrouleau thank you for your help.

I enabled the daemon systemctl enable bluetooth-autoconnect and it is listed in systemctl services as running, however the speaker did not connect automatically on restart or login. Don't know why: perhaps it's something about my Manjaro or maybe I did something wrong.

I then used xfce4-session-settings -> Application autostart -> Add -> bluetooth-autoconnect, and now the Bluetooth speaker connects on every login, which I am very glad of.

jrouleau commented on 2019-07-31 13:25

@GrievousMa

A systemd service is installed with this package. Simply run systemctl enable bluetooth-autoconnect as root to automatically start in daemon mode where it will attempt to connect to any trusted devices once an adapter is powered on (such as after booting, resuming from suspend, etc.)

GrievousMa commented on 2019-07-31 13:15

It works well. Thanks!

Now I need to find how to automatically run bluetooth-autoconnect on every boot.

mareex commented on 2019-07-07 16:39

Thank you for this package. Works like a charm.