Wednesday, November 18, 2009

Browser Boot Camp

Greetings, fellow MindLeaders!

I was recently fortunate enough to lead a training session at the office. Given the fact that my employer is a company whose product is a web app, I saw an opportunity to train co-workers about what is going on with the World Wide Web and web browsers today (and tomorrow, for that matter). The one-hour training session was referred to as Browser Boot Camp and was a success, thanks in large part to the enthusiasm of the attendees.

The presentation can be downloaded in the following formats:

ODF (Open Office) | PDF

(You may need to right-click and choose Save Target As).

Creative Commons License
Browser Boot Camp by Rick Ucker is licensed under a Creative Commons Attribution-No Derivative Works 3.0 United States License.

Monday, November 9, 2009

Bitpim & Bluetooth Under Ubuntu Karmic

Last week, I gleefully installed Ubuntu 9.10, the Karmic Koala, on a new laptop. One of the first things on my to-do list was getting Bitpim set up so I could transfer ringtones & contacts between my laptop and my cell phone (a Verizon Wireless LG Dare).

To accomplish this, I looked up an old tutorial I had followed a while back for setting everything up on my old desktop machine.

I have found that a couple of things have changed since that guide has written, so I thought it would be worthwhile to post an updated version and share my findings.

Getting Started

Everything in this tutorial is possible under Karmic without installing any packages that aren't installed by default (except for Bitpim, of course).

This works for my LG Dare (Firmware version 05) and should work for many/most/all other Verizon LG phones that support the proper Bluetooth profiles -- possibly many more beyond that.

Just to keep things relatively short, we will assume that you have already managed to pair your phone with your computer.

Unless otherwise specified, assume any commands I ask you to issue will be done in Terminal.

Step 1: Find your phone's MAC address

The easiest way to do this is to browse the device via Nautilus: from the Bluetooth icon in the Gnome Panel, choose your device and then choose Browse Files. This will open a new Nautilus window and your phone's MAC address will be displayed in the address bar in the format obex://[mac:address:here]/.

Step 2: Find the channel used by the Bluetooth Serial Port service

Issue the command: sdptool browse mac:address:here.

My Dare uses Channel 5 for Serial Port as shown here:

Service Name: Serial Port
Service RecHandle: 0x10006
Service Class ID List:
  "Serial Port" (0x1101)
Protocol Descriptor List:
  "L2CAP" (0x0100)
  "RFCOMM" (0x0003)
    Channel: 5

Note: Some phones may not show anything labeled "Serial Port". In the case of my old phone (an LG VX9900), for example, I used the BT DIAG service instead and it worked. If you don't have a Serial Port section, you may have to try another service instead (but no guarantees it works).

Step 3: Create an RFCOMM binding by editing the appropriate config file

Open the config file by running: gksudo gedit /etc/bluetooth/rfcomm.conf

Uncomment the rfcomm0 section (remove the # from each line) and change it to look like this:

rfcomm0 {
    # Automatically bind the device at startup
    bind yes;

    # Bluetooth address of the device
    device mac:address:here;
    # RFCOMM channel for the connection
    channel 5;

    # Description of the connection
    comment "Needed by BitPim";

Step 4: Make sure your bluetooth bindings are added at startup

Due to a bug in 9.10, the rfcomm bindings that we specified above (in rfcomm.conf) will probably be ignored at startup. Reply #5 in the LP bug report provides a workaround for this issue. The instructions there are written for users who have upgraded to 9.10-- on my fresh 9.10 installation however, I needed only to follow step 3, which I will repeat here.

Open rc.local (gksudo gedit /etc/rc.local) and add the line:

rfcomm bind yes

Above the last line (which should say exit 0).

Step 5: Restart the Bluetooth service

Issue the commands:

sudo /etc/init.d/bluetooth stop
sudo /etc/init.d/bluetooth start

Note: running sudo /etc/init.d/bluetooth restart did not work for me: this caused the BT service to stop, but it wouldn't start again on its own. I had to issue "start" to get it to start again.

Step 6: Start Bitpim and check available com ports

Start Bitpim and go into Settings, then click the Browse... button to the right of "Com Port". You should see "Bluetooth (/dev/rfcomm0) listed under Available Ports. If you do, you are all set! You can now start reading/writing your phone data using Bitpim. If not, you may have done something wrong. Double check your work above and try again before continuing.

Step 7: Have fun hacking away at your phone!

If you have any questions or run into problems, please be as specific as possible when asking for help.

Thanks to:

Ars Technica