Bluetooth Mouse connects and disconnects every 0.5 seconds after (re)booting

I have a Logitech M535 Bluetooth mouse, but, even tho it’s paired already, I have to put it on pairing mode and connect it manually every time I turn on my PC. Otherwise it goes like:

[CHG] Device 34:88:5D:B3:C2:64 Connected: yes
[CHG] Device 34:88:5D:B3:C2:64 Connected: no
[CHG] Device 34:88:5D:B3:C2:64 Connected: yes
[CHG] Device 34:88:5D:B3:C2:64 Connected: no
[CHG] Device 34:88:5D:B3:C2:64 Connected: yes
[CHG] Device 34:88:5D:B3:C2:64 Connected: no
[CHG] Device 34:88:5D:B3:C2:64 Connected: yes
[CHG] Device 34:88:5D:B3:C2:64 Connected: no
[CHG] Device 34:88:5D:B3:C2:64 Connected: yes
[CHG] Device 34:88:5D:B3:C2:64 Connected: no

I want to know if there’s any way to make my PC connect to my mouse without having to always pair it again. Thanks.

I’m running dualboot with Windows 10 Home and Manjaro Linux XFCE 21.3.0
Kernel Version: 5.15.48-1-MANJARO
blueZ is updated;
bluetooth service is running;
device is paired and trusted;
any more information needed, please just ask.

Do you have TLP or LMT installed? If yes, exclude bluetooth USB from being automatically suspended. Otherwise, try unpairing completely first then pair again.

I finally fixed it.
Ok, so I found TLP and disabled the autosuspend. It didn’t work, but I left it like that though.
Here’s everything I did to fix it after that:

First of all, I unpaired and disconnect my mouse, then:

  1. sudo nano /etc/default/grub
  2. added “btusb.enable_autosuspend=0” to GRUB_CMDLINE_LINUX_DEFAULT at the end, inside the quotes, just to be sure
  3. saved and exited
  4. update-grub
  5. sudo btmgmt
  6. connectable on
  7. pairable on
  8. bredr on
    exited
  9. bluetoothctl
  10. agent on AND default-agent
  11. scan on
  12. put my mouse on pair mode
  13. trust mouse MAC address
  14. connect mouse MAC address

After all that, for some reason, the mouse info showed in bluetoothctl changed from Legacy Pairing “On” to “Off”.

I restarted my PC, and when I moved my mouse it turned on and connected like normal, no pairing required, yay!

After booting into Windows the same problem happened again, but if I only boot Linux, it doesn’t happen.
After getting the link keys from my Windows files (exactly like in ArchWiki Bluetooth page “Extracting on Linux” section [if you’re reading this in the future and that doesn’t work, check if Windows Fast Boot is off]), all I had to do was:

# btmgmt
[mgmt] connectable on
[mgmt] ltks
[mgmt] exit
# systemctl restart bluetooth  

and boom, just moving my mouse around instantly connected it again

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.