I have a bluetooth mouse (Apple Mighty Mouse) which I use with Kubuntu (KDE). I always have to manually connect to the mouse, although it is listed as a trusted device. How can I automatically connect the mouse when I have it turned on? Or at least reconnect after suspend?
You can use
hciconfig
to do that.First manually connect your mouse as you usually do, then open a terminal and run
hciconfig -a
to retrieve its name. It should be something likehciX
whereX
is the number of your device. You can either usehcitool scan
, it should give the name as well.Once this is done, you can force the bluetooth device detection by running
In order to do that automatically at every boot, you want to edit
/etc/init.d/bluetooth
and append the magic line at the end of the file :hciconfig <name_of_your_mouse> reset
. Then save, reboot, and it should work forever.Also make sure that your mouse is plugged in at boot time. If you plug it in after booting you will have to manually detect the mouse again.
Hope this helps.
I have a Logitech bluetooth travel mouse. I have Ubuntu 20.04. My laptop is a Lenovo ideapad. How to fix Bluetooth in Ubuntu
First, if bluez is installed. make sure the mouse is detected and paired. If not remove mouse icon, press the button on the mouse to pair and reconnect the mouse.
next: open terminal
To turn it on enter:
To make it permanent when booting up the system enter:
Also:
And to remove and reinstall the bluetooth stack and programs if it is corrupted use:
Install blueman:
Edit the main.conf file:
uncomment
ReconnectAttemps=7
(remove#
character) and also uncomment (remove #)Save, exit nano and reboot.
To remove blueman icon in upper right corner, right-click on blueman icon then uncheck appindicator under plugins.
Make sure to close cover and turn off mouse. Wait for suspend mode to occur (blinking power light), then turn on mouse then open lid on. The mouse will automatically connect.