Bluetooth mouse/kbd doesn't reconnect on bootup because hci0 not in scanning mode

Bug #79394 reported by Bart Samwel
16
This bug affects 1 person
Affects Status Importance Assigned to Milestone
bluez-utils (Ubuntu)
Undecided
Bluetooth
Nominated for Hardy by Jackflap
gnome-bluetooth (Ubuntu)
Undecided
Unassigned
Nominated for Hardy by Jackflap

Bug Description

Binary package hint: bluez-utils

After booting up, my bluetooth hardware is not in scanning mode, hciconfig lists hci0 as "UP RUNNING" but not scanning, even though hcid.conf enables both pscan and iscan. I then do this:

sudo hciconfig hci0 down
sudo hciconfig hci0 up

and then hciconfig lists hci0 as up, running *and scanning*.

Symptoms: my devices don't automatically reconnect at bootup. After running the above commands, my mouse and keyboard automatically reconnect.

Temporary hack: I fixed up my machine by putting the above two commands in /etc/init.d/bluetooth at the end of the "start" section. It's a hack, but it works for me.

Hardware: Dell Inspiron 9400 with a built-in Dell bluetooth dongle (manufactured by Broadcom according to what I see in hal-device-manager) that presents itself as an USB dongle.

Revision history for this message
lightenup (chrisweakland) wrote :

I have run into the exact same problem with Edgy Eft and Feisty Fawn but NOT on Dapper Drake! I have a Compaq nc6000 with a built in bluetooth receiver. I am using a Logitech v270 bluetooth mouse. The first thing you to do is modify the following line in /etc/default/bluez-utils

From:
HIDD_ENABLED=0

To:
HIDD_ENABLED=1

Next we need to modify the /etc/init.d/bluetooth file look for the section start_hid():

From:

[ "$VERBOSE" != no ] && log_success_msg "Starting $HIDD_NAME..."
fi
}

To:

[ "$VERBOSE" != no ] && log_success_msg "Starting $HIDD_NAME..."
sudo hciconfig hci0 down
sudo hciconfig hci0 up
fi
}

Next we need to pair the device:
For my Logitech v270 I had to power off the mouse and then power it back on. Next, press and release the reset button. At this point you should see the green LED blnking on the bottom of the mouse. Back on the command line, enter in the following command:

sudo hidd --search

At this point your mouse should be working, now give the box a reboot and hopefully it will continue to work!

Revision history for this message
lightenup (chrisweakland) wrote :

My last post was a fix that worked under Feisty Fawn

Revision history for this message
Bart Samwel (bart-samwel) wrote :

In fact, I've applied that exact same fix myself. And it works for me as well, except for the fact that I have to reapply it every time the bluetooth init.d script is upgraded. Should be in base, or the underlying bug should be fixed (preferably). It's probably a kernel problem more than a userspace problem.

Revision history for this message
encoded (encoded) wrote :

Just a comment to mention that I'm having the same problem with Fiesty Fawn.

I'm using a Logitech USB Bluetooth receiver, part of the DiNovo Media Desktop setup (usb bluetooth receiver, keyboard, and mouse)

Revision history for this message
Jackflap (deriziotis) wrote :

Confirmed on Ubuntu 7.10. bluez-utils 3.19 with both the following usb bluetooth adapters and a MS Intellimouse Explorer:

Edimax EB-DGC2
Trust BT120

My dmesg displays the following messages whenever I move the mouse before running hciconfig hci0 reset:

[ 169.162683] hci_acldata_packet: hci0 ACL packet for unknown connection handle 42
[ 169.173697] hci_acldata_packet: hci0 ACL packet for unknown connection handle 42
[ 169.185666] hci_acldata_packet: hci0 ACL packet for unknown connection handle 42

After running the following, the connection re-establishes:

sudo hciconfig hci0 down
sudo hciconfig hci0 up

I can also run sudo hciconfig hci0 reset in order to get the mouse to reconnect again. I've added the line to a startup script as a temporary fix.

Changed in bluez-utils:
status: New → Confirmed
Changed in gnome-bluetooth:
status: New → Confirmed
Changed in bluez-utils:
assignee: nobody → bluetooth
Revision history for this message
avdzm (alecos85) wrote :

I have Ubuntu 7.10,
this bug still exists.

My bluetooth mouse couldn't connect.
I get this error message, when i move or click a button on the mouse.
Feb 28 18:42:58 avdzm-laptop kernel: [ 96.888000] hci_acldata_packet: hci0 ACL packet for unknown connection handle 42
Feb 28 18:42:58 avdzm-laptop kernel: [ 96.900000] hci_acldata_packet: hci0 ACL packet for unknown connection handle 42
Feb 28 18:42:58 avdzm-laptop kernel: [ 96.912000] hci_acldata_packet: hci0 ACL packet for unknown connection handle 42
Feb 28 18:42:58 avdzm-laptop kernel: [ 96.924000] hci_acldata_packet: hci0 ACL packet for unknown connection handle 42
Feb 28 18:42:58 avdzm-laptop kernel: [ 96.932000] hci_acldata_packet: hci0 ACL packet for unknown connection handle 42
Feb 28 18:42:58 avdzm-laptop kernel: [ 96.944000] hci_acldata_packet: hci0 ACL packet for unknown connection handle 42
Feb 28 18:42:58 avdzm-laptop kernel: [ 96.956000] hci_acldata_packet: hci0 ACL packet for unknown connection handle 42

I added lines, and it's fixed now
sudo hciconfig hci0 down
sudo hciconfig hci0 up

thanks lightenup and Bart Samwel

I don't understand why this bug still exists, It's been almost a year
(according to the first post date)

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers