Friday, August 31, 2007

Solving problems Connecting bluetooth headset

So, I spent way too long fighting with my linux bluetooth system getting it to connect to my bt headset again. So, to help me remember what I learned this time I am going to add some info.
It looks to me like the behavior changes when kbluetoothd is running as opposed to when it is not running. don't know why. May have something to do with hcid having someone to show the ui to ask for the pin. I have it set to always ask for a pin in the yast config with I believe modifies the /etc/bluetooth/hcid.conf file, but in my file it says it uses /bin/bluepincat which is a little weird since the hcid.conf file says that it just returns the contents using /etc/bluetooth/pin file. When I run it from the console it actually asks for a pin which I assume would be stored somewhere.

When you go to the kbluetoothd configure paired devices. there is a link to a File location setup.
This tells me that the Link Key Directory is /var/lib/bluetooth/. So, I suspect that either bluepincat or hcid, who calls bluepincan is storing them in the /var/lib/bluetooth directory.

For some reason when I tried to connect the bt headset it would fail saying that it could not authenticate and the connection timed out.

So, I removed the pairing using kbluetoothd and then I tried to recreate it. I did this by putting the headset in pairing mode but somehow you need to get it to request a secure connection. I tried all kinds of things to get this to happen. What appears to have worked was to stop kbluetoothd then restart bluetooth with 'rcbluetooth restart' as root.
Then I started kbluetoothd again and went to the recently paired devices and clicked on the one that was my headset and said to show the services. Then finally it showed the pin promt.
when i was done there was an entry in the Link key directory. Then everything started working again.

0 Comments:

Post a Comment

<< Home