bernizt
Posts: 11
Joined: Sun Dec 15, 2013 3:05 pm

Bluetooth Dongle not detected by hcitool

Sun Dec 15, 2013 3:18 pm

Hello,

Yesterday I updated all packages of my raspberry pi (raspbian) and my bluetooth usb dongle stopped working.
I am using bluetooth, bluez-utils and blueman.

Executing "uname -a" shows:

Code: Select all

Linux raspberrypi 3.10.24+ #610 PREEMPT Thu Dec 12 13:12:09 GMT 2013 armv6l GNU/Linux
bluetooth is running (etc/init.d/bluetooth status )

Executing "lsusb" shows:

Code: Select all

   Bus 001 Device 004: ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode)
Executing "hciconfig -a" shows:

Code: Select all

hci0:	Type: BR/EDR  Bus: USB
	BD Address: 00:19:86:00:24:F0  ACL MTU: 1017:8  SCO MTU: 64:0
	DOWN 
	RX bytes:905 acl:0 sco:0 events:31 errors:0
	TX bytes:136 acl:0 sco:0 commands:32 errors:0
	Features: 0xff 0xff 0x8d 0xfe 0x8f 0xf9 0x00 0x80
	Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3 
	Link policy: 
	Link mode: SLAVE ACCEPT 
Executing "hcitool dev":

Code: Select all

   Devices:
(no devices, so I cannot start hci0, scan, connect, pair, etc.)

Anyone is experiencing the same problem? Any solution?

Thanks!
Last edited by bernizt on Sun Dec 15, 2013 4:43 pm, edited 1 time in total.

User avatar
Douglas6
Posts: 4645
Joined: Sat Mar 16, 2013 5:34 am
Location: Chicago, IL

Re: Bluetooth Dongle not detected by hcitool

Sun Dec 15, 2013 4:21 pm

Normally the adapter is brought up at boot, but yours is down as shown by the hciconfig results. Do this:

Code: Select all

sudo hciconfig hci0 up
hcitool dev
and see if that persists a reboot. To make it discoverable:

Code: Select all

hciconfig hci0 piscan 
Or 'noscan' to make it undiscoverable.

bernizt
Posts: 11
Joined: Sun Dec 15, 2013 3:05 pm

Re: Bluetooth Dongle not detected by hcitool

Sun Dec 15, 2013 4:42 pm

Thanks for the answer, but I cannot turn it up:

Running "sudo hciconfig hci0 up" I get:

Code: Select all

Can't init device hci0: Operation not supported (95)

User avatar
Douglas6
Posts: 4645
Joined: Sat Mar 16, 2013 5:34 am
Location: Chicago, IL

Re: Bluetooth Dongle not detected by hcitool

Sun Dec 15, 2013 5:04 pm

Well, that would explain why it wasn't brought up automatically. I'll see if if I can reproduce the issue tonight. Are you running Raspian, and this occurred after an apt-get upgrade?

bernizt
Posts: 11
Joined: Sun Dec 15, 2013 3:05 pm

Re: Bluetooth Dongle not detected by hcitool

Sun Dec 15, 2013 5:08 pm

Yes, I'm running Raspbian, and this happened yesterday after apt-get update, apt-get upgrade

I am running:

Code: Select all

Linux raspberrypi 3.10.24+ #610 PREEMPT Thu Dec 12 13:12:09 GMT 2013 armv6l GNU/Linux
.

thanks!

User avatar
redhawk
Posts: 3465
Joined: Sun Mar 04, 2012 2:13 pm
Location: ::1

Re: Bluetooth Dongle not detected by hcitool

Sun Dec 15, 2013 5:09 pm

It would appear this stupid bug hasn't been fixed yet - http://www.raspberrypi.org/phpBB3/viewt ... 70#p285970
I wrote a quick and dirty script to correct this (including class type and device name) feel free to use it. :)

Richard S.

bernizt
Posts: 11
Joined: Sun Dec 15, 2013 3:05 pm

Re: Bluetooth Dongle not detected by hcitool

Sun Dec 15, 2013 5:23 pm

Thanks redhawk, but I had already read your post: the dongle is not detected even if I plugged it in after boot.

User avatar
Douglas6
Posts: 4645
Joined: Sat Mar 16, 2013 5:34 am
Location: Chicago, IL

Re: Bluetooth Dongle not detected by hcitool

Sun Dec 15, 2013 5:26 pm

It does sound like a problem with the class. It might be interesting to see what's in your /var/lib/bluetooth/<xx:xx:xx:xx:xx:xx>/config file. Mine (working, also a CSR dongle) looks like this:

Code: Select all

cat /var/lib/bluetooth/00\:15\:83\:0C\:BF\:EB/config
name raspberrypi-0
pairable yes
class 0x420100
onmode discoverable
mode discoverable
Last edited by Douglas6 on Sun Dec 15, 2013 5:44 pm, edited 1 time in total.

bernizt
Posts: 11
Joined: Sun Dec 15, 2013 3:05 pm

Re: Bluetooth Dongle not detected by hcitool

Sun Dec 15, 2013 5:43 pm

Douglas8, class is the same one that you have:

/var/lib/bluetooth/00:19:86:00:24:F0 $ cat config

Code: Select all

name raspberrypi-0
pairable yes
class 0x420100

User avatar
Douglas6
Posts: 4645
Joined: Sat Mar 16, 2013 5:34 am
Location: Chicago, IL

Re: Bluetooth Dongle not detected by hcitool

Sun Dec 15, 2013 5:55 pm

bernizt wrote:Douglas8
I got promoted :)

I'm shooting in the dark here (obviously), but you might try moving that entire directory away and rebooting. Maybe some cache is not happy with the new distro. DId Bluez get upgraded?

Code: Select all

dpkg --status bluez | grep '^Version:'
Version: 4.99-2
I have to run out and do family stuff now (I hate the holidays; bah, humbug). Good luck!

bernizt
Posts: 11
Joined: Sun Dec 15, 2013 3:05 pm

Re: Bluetooth Dongle not detected by hcitool

Sun Dec 15, 2013 6:13 pm

Hehe sorry for the typo!

Yes I have bluez Version: 4.99-2. Just removed everything (including that folder) and reinstalled again. Still no luck…

Thank you anyway, Douglas6!

bernizt
Posts: 11
Joined: Sun Dec 15, 2013 3:05 pm

Re: Bluetooth Dongle not detected by hcitool

Mon Dec 16, 2013 10:13 pm

I have tested the dongle in another device and it works. I have just done a fresh install and updated.
The problem still persist. Maybe a bug in this version?

Code: Select all

Linux raspberrypi 3.10.23+ #608 PREEMPT Mon Dec 9 21:11:23 GMT 2013 armv6l GNU/Linux

bernizt
Posts: 11
Joined: Sun Dec 15, 2013 3:05 pm

Re: Bluetooth Dongle not detected by hcitool

Tue Dec 17, 2013 12:18 am

Ok, it is definitely a bug.

I have downgraded to:

Code: Select all

Linux raspberrypi 3.9.5+ #466 PREEMPT Sun Jun 9 14:35:13 BST 2013 armv6l GNU/Linux
And now the device is shown with hcitool.

Where is the best place to report the bug? (raspberrypi github, Raspbian launchpad, ...)

andreap
Posts: 10
Joined: Thu Jan 02, 2014 6:32 pm

Re: Bluetooth Dongle not detected by hcitool

Fri Jan 03, 2014 3:46 pm

Hi,
do you know if this problem was fixed? I have the 3.10.24+ #614 kernel version and I have the same issue.... My bluetooth dongle is:
Cambridge Silicon Radio,Ltd Bluetooth Dongle(HCI mode).

Thanks
Andrea

knex
Posts: 1
Joined: Wed Jan 08, 2014 1:50 pm

Re: Bluetooth Dongle not detected by hcitool

Wed Jan 08, 2014 1:52 pm

This Bug is not Fixes, this is a workaround:
http://www.raspberrypi.org/phpBB3/viewt ... 70#p285970

andreap
Posts: 10
Joined: Thu Jan 02, 2014 6:32 pm

Re: Bluetooth Dongle not detected by hcitool

Tue Jan 14, 2014 11:21 am

Hi,
this workaround doesn't work with my issue. When I execute hciconfig device up I receive the error
Can't init device hci0: Operation not supported (95)

flamed
Posts: 1
Joined: Sun Mar 02, 2014 12:48 pm

Re: Bluetooth Dongle not detected by hcitool

Sun Mar 02, 2014 12:55 pm

Hi, is there any new about this issue?

Belokan
Posts: 2
Joined: Thu Mar 13, 2014 8:56 am

Re: Bluetooth Dongle not detected by hcitool

Thu Mar 13, 2014 9:24 am

Hi,

Just got exactly the same issue with my brand new RPi B/512 received yesterday together with an iClever Rii BT keyboard with Cambridge dongle. Dongle was seen in lsusb, hciconf -a showed device but DOWN state, etc, etc, ...

I've first tried to upgrade my kernel to the last available using rpi-update (3.10.33+ #654), but still the same problem.
I've then tried to downgrade the kernel as I've seen while googling around that many users have had this issue after an upgrade to a 9 months old (August '13) kernel using:

Code: Select all

rpi-update dc2196389c242cff158a709572a0207320a41830 (3.6.11+ #538)
And now it looks far better:

Code: Select all

[email protected]:~# hciconfig -a                                                                                          
hci0:   Type: BR/EDR  Bus: USB                                                                                    
        BD Address: 00:1B:10:00:2A:EC  ACL MTU: 1017:8  SCO MTU: 64:0                                             
        UP RUNNING PSCAN ISCAN                                                                                    
        RX bytes:1223 acl:0 sco:0 events:42 errors:0                                                              
        TX bytes:443 acl:0 sco:0 commands:42 errors:0                                                             
        Features: 0xff 0xff 0x8d 0xfe 0x9b 0xf9 0x00 0x80                                                         
        Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3                                                          
        Link policy: RSWITCH HOLD SNIFF PARK                                                                      
        Link mode: SLAVE ACCEPT                                                                                   
        Name: 'raspberrypi-0'                                                                                     
        Class: 0x420100                                                                                           
        Service Classes: Networking, Telephony                                                                    
        Device Class: Computer, Uncategorized                                                                     
        HCI Version: 2.0 (0x3)  Revision: 0x3000                                                                  
        LMP Version: 2.0 (0x3)  Subversion: 0x420b                                                                
        Manufacturer: Broadcom Corporation (15)                                                                   
                                                                                                                  
[email protected]:~# hcitool dev                                                                                           
Devices:                                                                                                          
        hci0    00:1B:10:00:2A:EC                                                                                 

[email protected]:~# hcitool scan                                                                                          
Scanning ...                                                                                                      
^C
I'm not @home right now and accessing the RPi remotely so I can not try the pairing but there's no reason it could fail now.

I've not planed to test every single kernel to find the higher "working" one but I'll test some and come back here to provided the UUID of the latest one I've successfully tested.

Cheers,

Olivier

EDIT:

Ok, testing was quite easy & fast. I first tried the first 3.10 kernel (3.10.18+ #577) and my hci0 was DOWN after reboot with all the symptoms described in this topic. Then I tried the last 3.6 kernel (3.6.11+ #557) and the hci0 is UP and all seems OK (bluez-test-*, hcitool dev/scan, etc, ...).

So for me the bug is within 3.10 kernel from the first #577 to the last #654 available. Downgrading to the last 3.6 solved the issue ... Just use:

Code: Select all

rpi-update 8234d5148aded657760e9ecd622f324d140ae891
To install the "correct" kernel.

Belokan
Posts: 2
Joined: Thu Mar 13, 2014 8:56 am

Re: Bluetooth Dongle not detected by hcitool

Thu Mar 13, 2014 4:37 pm

I've successfully paired the Keyboard now, so downgrading is (for me) a valid solution for this problem !

texy
Forum Moderator
Forum Moderator
Posts: 5156
Joined: Sat Mar 03, 2012 10:59 am
Location: Berkshire, England

Re: Bluetooth Dongle not detected by hcitool

Sat May 10, 2014 3:19 pm

The problem with bluetooth that I have at the moment is that my idevice isn't seeing the pi. My pi can see my iphone and and itouch, but not the other way round, so I cannot pair them :

Code: Select all

[email protected] ~ $ sudo hciconfig -a
hci0:   Type: BR/EDR  Bus: USB
        BD Address: 00:1F:81:00:08:30  ACL MTU: 1021:4  SCO MTU: 180:1
        UP RUNNING PSCAN ISCAN
        RX bytes:786 acl:0 sco:0 events:28 errors:0
        TX bytes:376 acl:0 sco:0 commands:27 errors:0
        Features: 0xff 0x3e 0x09 0x76 0x80 0x01 0x00 0x80
        Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
        Link policy: RSWITCH HOLD SNIFF
        Link mode: SLAVE ACCEPT
        Name: 'raspberrypi-0'
        Class: 0x4e0100
        Service Classes: Networking, Rendering, Capturing, Telephony
        Device Class: Computer, Uncategorized
        HCI Version: 2.0 (0x3)  Revision: 0x44
        LMP Version: 2.0 (0x3)  Subversion: 0x3
        Manufacturer: Cambridge Silicon Radio (10)

[email protected] ~ $ sudo hciconfig hci0 piscan
[email protected] ~ $ sudo /etc/init.d/bluetooth restart
[ ok ] Stopping bluetooth: rfcomm /usr/sbin/bluetoothd.
[ ok ] Starting bluetooth: bluetoothd rfcomm.
[email protected] ~ $ sudo hciconfig hci0 piscan
[email protected] ~ $ hcitool dev
Devices:
        hci0    00:1F:81:00:08:30
[email protected] ~ $ hcitool scan
Scanning ...
        00:23:DF:D4:0A:31       iTouch

[email protected] ~ $ sudo uname -a
Linux raspberrypi 3.6.11+ #557 PREEMPT Wed Oct 2 18:49:09 BST 2013 armv6l GNU/Linux
[email protected] ~ $

As you can see, I also downgraded the kernel, but that hasn't helped. This setup was working well for me some months ago, but not today......
Texy
Various male/female 40- and 26-way GPIO header for sale here ( IDEAL FOR YOUR PiZero ):
https://www.raspberrypi.org/forums/viewtopic.php?f=93&t=147682#p971555

User avatar
pi3g
Authorised Reseller
Authorised Reseller
Posts: 69
Joined: Mon Nov 05, 2012 9:58 pm
Location: Germany
Contact: Website

Re: Bluetooth Dongle not detected by hcitool

Mon Jul 28, 2014 9:30 pm

Just wanted to thank you for helping me:

Code: Select all

hciconfig hci0 piscan
did the trick to make my Pi discoverable! I already thought that maybe the Bluetooth dongle does not work the way I wanted it to (connect to Smartphone).

Thanks again!

:D
picockpit.com - tools to make your life with the Pi a little bit easier

Return to “Troubleshooting”