Archive for August, 2009

The Other Tether : The G1/Android as a Bluetooth PANU Client

Stop for a second to realize that your way of doing things is always the best way of doing things.  If only for no one else.

I’ve been playing with a G1, mostly for Google Voice/Sipdroid and My Maps Editor (for an upcoming vacation).  As I currently have a great plan with Sprint, and don’t want to drop the major coin required for the full voice and data package, I’ve got the G1 on the network with a pay-as-you-go Sidekick data plan.  No, it doesn’t really work for much, except SMS.  I have no need to make cellular calls, but I do want data while I’m out and about.  The Sidekick plan does NOT work for data on a G1.  It does register on the 3G/EDGE network, get an IP, set up the routes, and shoot, DNS even works.  But you cannot get ‘out’ to anything.  Yay T-Mobile for preventing me from giving you money you wouldn’t otherwise get at all, because lets face it, your network almost exists.

Thus my want for a BT PANU client.  As it turns out, cupcake includes pand and bluetooth networking support is built into the kernel.  Which is just about all you need.  Well, you might need root too.

Enough blathering.

First, you need the MAC of your Bluetooth Network Access Point.  I’m using Internet Sharing on Windows Mobile, so I just need my phone’s BT MAC, for instructional purposes, we’ll say it is: 00:15:81:3E:ED:02

Next create a shell script something like this:

#!/bin/bash
pand --connect 00:15:81:3E:ED:02
sleep 1
dhcpcd -d bnep0
setprop net.dns1 192.168.0.1

That last line sets your DNS / Name Server, it might be different depending on your BT NAP.  If you’re just using this at home instead of wireless because you’re bored or masochistic, then you’ll need to figure out what DNS info you need.  I just connected to Internet Sharing with my netbook first and checked what DNS servers it was configured to use.

One other thing to note:

If you have wireless disabled, and don’t have any SIM card inserted, then as far as Android is concerned, you have NO network connection.  Even after running the script above, only some Apps will work.  Maps works fine, as does Google Voice, but the Browser complains on open, then works fine.  Google Talk never opens at all.  Inserting a SIM card that shows an active 3G connection avoids this, but if I figure out an easier way (to save on the losses of cellular radio) I’ll post it.

Comments off

Using the G1 “with Google” Voice and without cellular service.

If you hadn’t noticed, I’m a fan of Google Voice..  But after a couple days with the G1, now I’m a fan of Android too.

As I am currently unable to switch providers, I wanted to use the G1 without cellular service.  I won’t go into the process of getting past the “No SIM Card” screen, as that’s a whole other story; but I will tell you how to configure a G1, or other Android device, to pretty much work perfectly with Google Voice.

Requirements:

  • G1, or some other Android device
  • Active Google Voice account
  • Active Gizmo5 account linked in Google Voice’s Phone Settings
  • Google Voice (the official app)
  • Sipdroid
  • GV (thanks to Evan Charlton for this)

The process:

First install Google Voice (the official app) and configure with the following options:

  • Making Calls - Do not use Google Voice for any calls
  • This Phone’s Number - select your gizmo5 number

Next install GV and configure it.  Enter your account info and click next.  When it shows your Phones, just click next, lastly for your GV Settings:

  • Route all calls through GV - Checked
  • Calling method - Call back
  • Your callback number - Gizmo5 number
  • Voicemail PIN - 1234

The last two options don’t actually matter in this setup, or anyone using callback, but they’re required by GV because Evan left out a conditional statement somewhere.. :p

Lastly, install and configure Sipdroid:

  • Username/Password - the Gizmo5 account you created
  • Server - proxy01.sipphone.com
  • Port - 5060
  • Use WLAN - checked
  • Preferred Call Type - Phone

So, how does this work?  When you attempt to create a call from the Contacts or Dialer, Evan’s GV app takes control and initiates a callback via your G1’s internet connection.  This instantiates an incoming call from Google Voice, through your Gizmo5 account, which Sipdroid catches.  The beauty of this configuration is that Sipdroid and GV both integrate into the G1 so well that everything looks like a normal incoming or outgoing call..

Noteworthy:  It may be possible to configure Sipdroid to initiate callbacks directly, thus negating the need for GV, but I’m too lazy to bother trying to figure it out right now.  Also, Google Voice’s usefulness is questionable..  The Visual Voicemail is awesome, but the text messages don’t show up instantly, in fact, I’m not sure how often it polls for new messages, or if it only checks when the app is started, or when you Refresh from the Menu.

Good luck, and happy ‘off-the-grid’ calling.

Comments off