BluetoothDialup

Differences between revisions 9 and 10
Revision 9 as of 2006-04-08 02:16:55
Size: 7523
Editor: S0106000fb085cc63
Comment: add cat doc
Revision 10 as of 2006-04-08 09:55:10
Size: 7697
Editor: rrcs-24-153-226-7
Comment:
Deletions are marked like this. Additions are marked like this.
Line 152: Line 152:
 * You should now be able to ping {{{ubuntu.com}}}; expect latencies of around one second for most GPRS services
 * If pinging fails, see the troubleshooting section below

This page describes how to configure PPP dialup through a Bluetooth-compatible mobile phone. The emphasis is on using GPRS/EDGE services. These instruction were compiled and tested on the Dapper Drake development release.

Configure mobile phone data profiles

Getting the data access profile

T-Mobile

T-Mobile accounts generally require separate data profiles for WAP and general data access. (Some people have had success running a regular data connection over the WAP profile.) Getting access to general data access requires a data access plan. Currently, the "Unlimited Internet VPN" is the best deal, as it costs the same as the "Unlimited Internet" plan but gives you a real, public IP address. Incoming connections are blocked on any T-Mobile data plan. T-Mobile does not seem to offer metered data plans anymore.

There are two ways to get the data service profile on your phone.

Automatic

T-Mobile can send the data services profile directly to your phone via SMS. Only the "wireless data" customer service people can send the data services profile to your phone. The regular service people can only send the WAP data profile, which will not work for general use. You will have to be transferred once or twice to reach the wireless data division. Once there, simply request that the data service profile for your plan be sent to your phone. (Of course, you'll need to be signed up for a data plan.)

Once you receive the plan information, your phone will ask you where you want to store it. T-Mobile uses profile 1 for the WAP profile, so don't overwrite it. I recommend using profile 2, as it's usually the first empty profile.

After storing the data services profile, your phone will probably set it as the default. This will probably cause your WAP (T-Zones/T-Mobile Internet) to fail for your on-phone browser. Set the WAP data profile (profile 1) to default fix this. See the configuration section below for your phone's brand. Setting the default profile is usually fairly obvious once you've reach the data services configuration screen.

Manual

Access the data profiles configuration for your phone's brand using the instructions under the configuration section below. The order and name for settings is for a Samsung T809. These settings are verbatim from the SMS T-Mobile sends Unlimited Internet VPN plan users.

Use the following settings for the Unlimited Internet VPN plan:

  • Name: T-Mobile VPN

  • Home URL: http://www.t-mobile.com

  • Bearer: GPRS only

  • Proxy use: Disable

  • GPRS settings
    • DNS1: 0.0.0.0

    • DNS2: 0.0.0.0

    • APN: internet3.voicestream.com

    • Login ID: Empty

    • Password: Empty

Other companies

Call your mobile service provider and request information about data plans. Many charge by the megabyte, but unlimited plans are increasingly available. Most of the instruction for T-Mobile will probably apply.

Configuration

Sony Ericsson GSM

This is from my memory of using a T610, but it should apply to any Sony Ericsson phone. Choose the lower-left icon from the main menu.

Samsung GSM

This is tested on a T809, but should apply to any Samsung GSM phone. Enter code *#87927# from the main screen. Select "Current profile" to choose the default profile. Select "Profile settings" to manage profiles.

Installing Bluetooth packages

Run the following at a shell prompt:

sudo apt-get install bluez-utils bluez-pin pppconfig

Listing Bluetooth devices

  • Make your phone Bluetooth discoverable.
  • Run the following at a shell prompt:

hcitool scan
  • Copy the MAC address (the text with the capital letters, numbers, and ':'s) somewhere convenient. You'll need it many times.

Pairing

  • Run

sudo gedit /etc/bluetooth/hcid.conf
  • Modify the pin_helper setting from /usr/bin/pinwrapper to /usr/bin/bluez-pin

  • Save and close the hcid.conf file

  • Run

sudo /etc/init.d/bluetooth restart
  • Run the following, replacing your-phone-mac-address with the proper data

hcitool cc your-phone-mac-address
  • Run the following, replacing your-phone-mac-address with the proper data

hcitool auth your-phone-mac-address
  • Enter a numeric code into the dialog box that pops up
  • Accept the pairing from your phone handset
  • Enter the same number on your phone
  • Run the hcitool auth your-phone-mac-address command again if it fails

  • You can remove your handset's Bluetooth discoverability now

Configuring the rfcomm device

  • Get the channel number for your phone's dialup service by running the following, replacing your-phone-mac-address with the proper data

sdptool browse your-phone-mac-address
  • Look under "Service Name: Dial-up Networking"
  • Under "Protocol Descriptor List:" and "RFCOMM", there should be a number after "Channel:"
  • Remember that number; you'll need it for the rfcomm configuration
  • Run

sudo gedit /etc/bluetooth/rfcomm.conf
  • Paste the following into the file, replacing your-phone-mac-address and your-phone-rfcomm-channel with appropriate values

rfcomm0 {
        bind yes;
        device your-phone-mac-address;
        channel your-phone-rfcomm-channel;
        comment "Bluetooth PPP Connection";
}
  • Save and close the rfcomm.conf file

Configuring PPP

  • Run

sudo gedit /etc/ppp/peers/BluetoothDialup
  • Paste the following into the file (the file should start out blank)

debug
noauth
connect "/usr/sbin/chat -v -f /etc/chatscripts/BluetoothDialup"
/dev/rfcomm0 115200
defaultroute
crtscts
lcp-echo-failure 0
  • Save and close the BluetoothDialup file

  • Run

sudo gedit /etc/chatscripts/BluetoothDialup
  • Paste the following into the file (the file should start out blank), replacing your-apn-here with the APN from your data services profile (probably "internet3.voicestream.com" if you're on T-Mobile) and your-data-profile-number-here with the number you stored the profile into on the phone (probably 2)

TIMEOUT 35
ECHO    ON
ABORT   '\nBUSY\r'
ABORT   '\nERROR\r'
ABORT   '\nNO ANSWER\r'
ABORT   '\nNO CARRIER\r'
ABORT   '\nNO DIALTONE\r'
ABORT   '\nRINGING\r\n\r\nRINGING\r'
''      \rAT
OK      'AT+CGDCONT=2,"IP","your-apn-here"'
OK      ATD*99***your-data-profile-number-here#
CONNECT ""
  • Save and close the BluetoothDialup file

Authorizing dialout

Run the following at a shell prompt, replacing your-username-here with your username:

sudo adduser your-username-here dialout

Connecting

  • Run

pon BluetoothDialup
  • Wait about 30-60 seconds
  • You should now be able to ping ubuntu.com; expect latencies of around one second for most GPRS services

  • If pinging fails, see the troubleshooting section below

Troubleshooting

  • Monitor /var/log/syslog for dialup status information

  • Run ifconfig to check your PPP connection

  • Check /etc/resolv.conf to check your DNS configuration

  • Remove any non-loopback and ppp connections by running the following, replacing your-extra-interface with the appropriate names

sudo ifconfig your-extra-interface down
  • Check the routing table by running route

Disconnecting

Run

poff BluetoothDialup

Other useful guides


CategoryHardware CategoryDocumentation

BluetoothDialup (last edited 2008-08-06 16:17:36 by localhost)