I have a laptop running Ubuntu 18.04 which is paired with an external Bluetooth speaker. It takes me seven mouse clicks to connect to this speaker (such as when the laptop has been outside range of the speaker).
- Click upper right corner of screen
- Click Bluetooth icon
- Click Bluetooth Settings
- Click device name
- Click Connection
- Click window close
- Click window close
Is there a way to connect to a USB device in fewer steps than this?
Take a look at a similar question/answer here.
First, the MAC Address of the Bluetooth device is needed. You can find it by running the following commands:
sudo systemctl start bluetooth
bluetoothctl
(a new bash prompt "[bluetooth]#" will be visible after running this command)devices
Finally, run the following commands which start the Bluetooth service and passes the commands through the echo program. These two commands are what you need to connect to your bluetooth device over the terminal.
sudo systemctl start bluetooth
echo -e 'connect YOUR_DEVICE_MAC_ADDRESS \nquit' | bluetoothctl
This can be put in a bash script and the bash script can be automated to run upon startup.
Created this simple script to toggle the bluetooth device.
In addition to the CLI-based solutions in other answers, there is a Gnome extension called Bluetooth quick connect which streamlines the GUI a lot. It adds a toggle button to the Bluetooth menu for each paired device, which cuts your number of clicks down to three.
Screenshot of bluetooth-quick-connect extension
The easiest way to install Gnome extensions is to first install the Gnome extensions manager (
apt install gnome-shell-extensions
) and the Firefox plugin (which will be linked at the top of the extension's webpage). After that, installing any Gnome extension is just a case of clicking the toggle button at the top of the corresponding webpage.I noticed that if you are already connected to the bluetooth device, you can just sudo systemctl start bluetooth
bluetoothctl
you get a screen show the device in this case "Basilisk X Hyperspeed" in blue
I just typed in "trust"
it said changing "Your MAC address" trust succeeded