Using Bluetooth

My friend Ben gave me his old SonyEricsson T68i (which is one of the phones I've really wanted when it was new). It supports Bluetooth and AT&T Wireless provides my GPRS network, so this gives me something new with which to experiment.

I found a nicely-priced D-Link DBT-120 USB-BT dongle on eBay, and now I'm set. I thought it would be convenient just to be able to access the phone's modem functionality while it was still in my pocket, but it gets better than that -- I can put the phone on the other side of the house, where the GPRS signal is stronger and still access it from another room.

I recompiled my Linux 2.6.7 kernel with modules for: bluetooth, l2cap, rfcomm, hci_usb. I then installed Debian Unstable's latest bluez-utils package. I think the only bluetooth-specific configurations I needed to change was to add this section to the /etc/bluetooth/rfcomm.conf:

rfcomm0 {
    bind yes;
    device 00:0A:D9:13:0B:1B;
    channel 1;
    comment "T68i";
}
Restarting /etc/init.d/bluez-utils yielded a working /dev/rfcomm0 device which allows me to talk to the phone as a modem (just like ircomm0 in case of IRDA). I ran pppconfig and configured up a pretty standard modem-like PPP session using /dev/rfcomm0 as the device, bogus login and passwords, and relatively bogus default chat scripts. The important part is to dial to the right number: *99#.

My PPP connection kept dropping out after about 2 minutes, due to the lcp-echo requests not being answered. I had to disable lcp-echo requests with these 2 lines added to the /etc/ppp/peer/provider options file:

lcp-echo-failure 0
lcp-echo-interval 600
This disables failure, and additionally tells it to not ping so often (every 5 minutes now).

In my initial tests, I'm seeing about 4.5KiB/s, which isn't terrible for a completely mobile connection.


Filed Under: Linux Technology Computers