USB Bluetooth on Ubuntu - Issues with Roving Networks BT

All things pertaining to wireless and RF links

Moderator: phalanx

Post Reply
sharana
Posts: 25
Joined: Wed Nov 01, 2006 4:37 pm
Contact:

USB Bluetooth on Ubuntu - Issues with Roving Networks BT

Post by sharana » Wed Dec 26, 2007 12:55 pm

Hey Guys,

We've purchased one of the Roving Networks Bluetooth Modem from Sparkfun. I'm trying to connect to the bluetooth modem through a Bluetooth USB Dongle on my Dell Inspiron 600m laptop. The laptop is loaded with Ubuntu Linux (Fiesty Fawn ver 7.04). The bluetooth dongle recognizes (it can see) the Roving Network Bluetooth modem but its not able to establish a connection. I've tried hcitool and gbsco.

Using the hcitool utility it connects for a fraction of a second and then disconnects. The hcidump utility outputs something like "remote host terminated connection". If I try gbsco (gui version of bsco) the hcidump utility throws a RFCOMM error. If anyone has tried their hands and has been successful in establishing a connection please let me know. Any other input on this front will be really helpful.

Thanks guys,
sharan

wiml
Posts: 487
Joined: Tue Feb 08, 2005 11:45 pm
Location: Seattle, WA, USA
Contact:

Post by wiml » Thu Dec 27, 2007 6:29 pm

Does the bluetooth module have a setting to drop the connection when DTR drops (modem-style connection control)? If so try asserting DTR on the modem end, etc.

sharana
Posts: 25
Joined: Wed Nov 01, 2006 4:37 pm
Contact:

Post by sharana » Sun Dec 30, 2007 8:48 pm

Hey Guys,

I have the Roving Networks bluetooth modem working now. The link between my USB bluetooth (which sticks into my laptop) dongle and the bluetooth modem is up. I thought I'd post a how-to on the forum if anybody needed it. The software tools used to get it working are very basic and most Linux distributions with a 2.6 kernel should have them. The primary package which drives the dongle on linux is bluez-utils. Below are the steps...

1. Start the bluetooth device on the laptop with "sudo /etc/init.d/bluetooth start/restart"
2. Open up a terminal window and type "rfcomm". You should see a message which looks something like the one below.
rfcomm0: <FireFly-address> channel 1 clean
3. The settings for the rfcomm device (in our case its the FireFly) are in /etc/bluetooth/rfcomm.conf. The default device address there is that of the FireFly.
4. Type "rfcomm release 0"
5. Power off and switch on the FireFly device here.
5. Type "rfcomm bind 0 <FireFly-address> 1"
6. Type "gtkterm"

Its very important that you issue the gtkterm command when the FireFly is blinking rapidly (2 times per second). If its in discoverable/idle mode (blinking 1 time per second) the link will not work. This is the case for both Windows and Linux. I think its true for Mac too.

Once you've established the connection and the link is up you can type $$$ in the gtkterm window. A CMD will be returned and FireFly will start blinking more rapidly (10 times per second). If you type ---<cr> a END will be returned and FireFly will not blink at all.

The port specification for using it in a C program is "/dev/rfcomm0". An "rfcomm connect" opens the file /dev/rfcomm0 for writing and if this happens then you will not be able to open the port again in a C program for writing. If you potentially plan to use it in a C program or transfer files then keep the rfcomm port binded usring "rfcomm bind 0 <device-address> 1". I haven't really tried this myself. We'll be using it soon in our C program and I'll update the post then.

Thanks,
sharan

60amp_relay
Posts: 44
Joined: Fri Feb 26, 2010 12:12 pm

Re: USB Bluetooth on Ubuntu - Issues with Roving Networks BT

Post by 60amp_relay » Mon Jul 19, 2010 5:40 pm

Worked like a charm! I was having the same problem under Ubuntu 9.04, and your mini-howto solved the problem for me. Thanks for posting these instructions.

Post Reply