After several trial and error, I could manage my BB Curve 8310 as bluetooth modem on my Ubuntu Hardy box.
Resources:
https://help.ubuntu.com/community/BluetoothDialup
http://kapsi.fi/%7Emcfrisk/linux_gprs.html
My Device :
BB Curve 8310 OS 4.5.0.44 Beta Release 62 (Platform 2.7.0.61)
PC box : Ubuntu 8.04 Hardy Heron
Provider : Satelindo (Indonesia)
APN : satelindogprs.com (Username and Password blank)
=================================
STEP BY STEP CONFIGURATION
=================================
PART I – Configure Scripts
1. Download three scripts: gprs, gprs-connect-chat and gprs-disconnect-chat from HERE. These scripts are user friendly, full of self explanation.
2. Edit gprs script. Here I delete all commented line, but it is a good practice not to delete those line for troubleshooting.
- Edit Connect script section
# Connect script:
connect /etc/ppp/peers/gprs-connect-chat
- Edit Serial Device section
# Serial device to which the GPRS phone is connected:
/dev/rfcomm0
- Edit IP address section
# IP addresses:
:169.254.1.1
I’m not sure here, it probably depend on local LAN network? Before I change this address I got long repeated line on terminal console like this:
sent [IPCP ConfRej id=0xd3 <addr 169.254.1.1>]
rcvd [IPCP ConfReq id=0xd4 <addr 169.254.1.1>]
So I just use this address.
- Edit Username and password section
My provider setup for username and password is blank. If you have Username and Password you have some works here
# Username and password:
user “”
3. Edit script gprs-connect-chat. Change to your provider APN this line.
OK ‘AT+CGDCONT=1,”IP”,”satelindogprs.com”,”",0,0′ \
4. Copy all three scripts to /etc/ppp/peers/
5. Change files authorities. Use these commands:
$ sudo chown root:root /etc/ppp/peers/gprs*
$ sudo chmod u+rwx,g=rx,o=rx /etc/ppp/peers/gprs-connect-chat
$ sudo chmod u+rwx,g=rx,o=rx /etc/ppp/peers/gprs-disconnect-chat
PART II – Configure Bluetooth Connection
1. Bluetooth pairing
- On Ubuntu, set bluetooth discoverable
- From Blackberry initiate bluetooth pairing, input pin when asked
- On BB set the Ubuntu box as trusted after successfull pairing
2. Obtain Blackberry MAC address
- On BB go to Bluetooth Setting – Option. Write down the BB MAC Address.
3. Obtain BB Dialup Networking channel.
Set BB bluetooth discoverable and run this command:
$ sdptool search DUN
It will list all bluetooth DUN device in range. Find the Channel for Dialup Networking for our BB and remember this channel. The result will similar to this:
budjo@ubuntu:~$ sdptool search DUN
Inquiring …
Searching for DUN on 00:1C:CC:9D:AC:41 … => BB MAC Address
Service Name: Dialup Networking
Service RecHandle: 0×10000
Service Class ID List:
“Dialup Networking” (0×1103)
“Generic Networking” (0×1201)
Protocol Descriptor List:
“L2CAP” (0×0100)
“RFCOMM” (0×0003)
Channel: 1 => BB Bluetooth Dialup Networking Channel
Profile Descriptor List:
“Dialup Networking” (0×1103)
Version: 0×0100
4. Rfcomm device configuration
- Edit file /etc/bluetooth/rfcomm.conf , use this command:
$ sudo gedit /etc/bluetooth/rfcomm.conf
- Paste the following into the file, replacing your-BB-mac-address and your-BB-rfcomm-channel with appropriate values:
rfcomm0 {
bind yes;
device your-BB-mac-address;
channel your-BB-rfcomm-channel;
comment “Bluetooth BB Connection”;
}
For example :
rfcomm0 {
bind yes;
device 00:1C:CC:9D:AC:41;
channel 1;
comment “Bluetooth BB Connection”;
}
- Save and close the rfcomm.conf file.
- Restart bluetooth service. Use the folowing command:
$ sudo /etc/init.d/bluetooth restart
5. Bind the rfcomm channel
Run the following command on console:
$ sudo rfcomm bind 0 your-BB-mac-address your-BB-rfcomm-channel
For example :
$ sudo rfcomm bind 0 00:1C:CC:9D:AC:41 1
=============================
Now we are ready. Disable Local LAN network if you connected to LAN. Start the connection using this command on user mode:
$ pppd call gprs
If everything works it will show something like this:
budjo@ubuntu:~$ pppd call gprs
Press CTRL-C to close the connection at any stage!
defining PDP context…
rAT
OK
ATH
OK
ATE1
OK
AT+CGDCONT=1,”IP”,”satelindogprs.com”,”",0,0
OK
waiting for connect…
ATD*99#
CONNECT
Connected.
If the following ppp negotiations fail,
try restarting the phone.
Serial connection established.
using channel 1
Using interface ppp0
Connect: ppp0 <–> /dev/rfcomm0
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x124171e3>]
rcvd [LCP ConfReq id=0x0 <asyncmap 0x0> <auth pap>]
sent [LCP ConfAck id=0x0 <asyncmap 0x0> <auth pap>]
rcvd [LCP ConfRej id=0x1 <magic 0x124171e3>]
sent [LCP ConfReq id=0x2 <asyncmap 0x0>]
rcvd [LCP ConfAck id=0x2 <asyncmap 0x0>]
sent [PAP AuthReq id=0x1 user="ubuntu" password=""]
rcvd [PAP AuthAck id=0x1]
PAP authentication succeeded
sent [CCP ConfReq id=0x1 <deflate 15> <deflate(old#) 15>]
sent [IPCP ConfReq id=0x1 <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
rcvd [LCP ProtRej id=0x1 80 fd 01 01 00 0c 1a 04 78 00 18 04 78 00]
Protocol-Reject for ‘Compression Control Protocol’ (0×80fd) received
rcvd [IPCP ConfReq id=0x2 <addr 169.254.1.1>]
sent [IPCP ConfAck id=0x2 <addr 169.254.1.1>]
rcvd [IPCP ConfNak id=0x1 <addr 10.33.147.0> <ms-dns1 124.195.15.100> <ms-dns3 124.195.15.98>]
sent [IPCP ConfReq id=0x2 <addr 10.33.147.0> <ms-dns1 124.195.15.100> <ms-dns3 124.195.15.98>]
rcvd [IPCP ConfAck id=0x2 <addr 10.33.147.0> <ms-dns1 124.195.15.100> <ms-dns3 124.195.15.98>]
not replacing existing default route via 192.168.0.2
Cannot determine ethernet address for proxy ARP
local IP address 10.33.147.0
remote IP address 169.254.1.1
primary DNS address 124.195.15.100
secondary DNS address 124.195.15.98
Script /etc/ppp/ip-up started (pid 6271)
Script /etc/ppp/ip-up finished (pid 6271), status = 0×0
To disconnect DUN press CTRL-C
NOTE
1. Be carefull when copying from webpage since it seems mess up punctuations
2. Check your network provider subcription for GPRS data before using this connection.
TROUBLESHOOTING
* Error occured while binding rfcomm device
Error – Can’t create device: Address already in use. It is happened if the rfcomm device already bound to other device.
Solution
- Try to bind another rfcomm device, ie. rfcomm1. Use this command:
$ sudo rfcomm bind 1 your-BB-mac-address your-BB-rfcomm-channel
- Edit gprs script -> Serial Device section -> /dev/rfcomm1
- Add new rfcomm device to file /etc/bluetooth/rfcomm.conf. If you have two bluetooth device it will look like this:
rfcomm0 {
bind yes;
device other-bluetooth-device-mac-address;
channel other-bluetooth-device-rfcomm-channel;
comment “Other Bluetooth Device Connection”;
}
rfcomm1 {
bind yes;
device 00:1C:CC:9D:AC:41;
channel 1;
comment “Bluetooth BB Connection”;
}
11 June 2008 at 8:58 pm
[...] and error, I could manage my BB Curve 8310 as bluetooth modem on my Ubuntu Hardy box…. Visit HERE for complete story have fun [...]
15 July 2008 at 12:02 am
Thank you for your great how-to. I’ve got a problem: everything runs fine and the script says I am connected, but really I’m not. No IP address. The pppd service is correctly initiated, no errors in the log, but.. no connection. I’m giving up, unless you have some idea.
Thanks
Fabio
15 July 2008 at 10:31 am
I heard that some network block this modem connection, can you get it to work on Windows (just to cross check)?
16 July 2008 at 12:09 am
ehmm.. don’t have any windows installation available…
16 July 2008 at 12:09 am
Could I try with gnome-ppp instead of gprs script?
16 July 2008 at 12:59 am
I have tried again with gprs, and now the script seems to hang forever here:
sent [LCP ConfReq id=0x1 ]
sending a lot of “sent…” messages and never receiving a “rcvd..”
8 August 2008 at 10:55 pm
Same for me..never get rcvd signal
Last message is “Modem hangup”
8 August 2008 at 10:55 pm
If someone could bring assistance on this point, it would be cool ^^
25 August 2008 at 1:06 am
Probably you guys should see this page for other/simple methods:
http://naraku.net/2008/08/15/how-to-teather-blackberry-and-linux-via-bluetooth/
28 August 2008 at 6:42 am
[...] – near giving up. then a miracle: I stumbled upon a simple, straight-foward and *functional* bluetooth modem solution [...]
4 September 2008 at 7:11 pm
[...] the kapsi.fi link has nothing about Blackberry, but some good tips for discovery. And finally, this link helped with Ubuntu, but led me to find that my Blackberry is not supporting [...]
6 September 2008 at 6:12 am
The first time I tried this, it connected to the phone and continued as your example until it got to this line:
sent [PAP AuthReq…
It then kept sending that line over and over and then failed. Now when I try, it never gets recv commands back from the phone and the process times out. I have rebooted my computer and also restarted my BlackBerry but still no luck. Can anyone help with this?
I must say that your article has been hugely useful though. All other solutions I’ve found were either not explained well or too complicated. Thank you!
10 September 2008 at 8:04 pm
@Jeff
The best solution is to check the steps one by one, to make sure there is nothing missed.
Actually using blackberry as modem is somewhat useless with it’s slow gprs connection and I don’t realy use it in practical, maybe later with faster (3G/HSDPA) version of blackberry.
13 November 2008 at 9:33 pm
I have a 3g blackberry 8330, it uses edvo, it is posible to use it in this way? what I have to change in the scripts?
14 November 2008 at 9:04 am
I’ve gotten this to work using a bb8310, at&t, and eeebuntu. Found the settings I needed to adjust in options-advanced options->tcp put whatever you want for password and have the same password specified in the pap-secrets file. The APN can also be found there. This is pretty straight forward. Thanks! I will say that using it *is* close to useless, but a slow connection is better than no connection at all
15 November 2008 at 8:50 am
@Sargate
I think it’s should work, probably with some adjustments. The setup is actually based on basic common setup for any mobile phone connection.
@oranges
Yes,you’re right, slow connection is better than no connection at all
24 November 2008 at 4:13 am
sent [PAP AuthReq…
It then kept sending that line over and over and then failed. …
I have the same problem like Jeff. Neither rebooting of the Blackberry nor of my notebook helps. I tried for hours and was searching the web around the globe
Has anybody a hint?
Thank you
jo
7 December 2008 at 5:05 am
Hello,
meanwhile I found the solution for the problem of endless “sends” without any “receives”.
It is a bug in Blackberry firmware. I upgraded to version 4.5 and the gprs script went well. No more problems!
As far as I read in http://www.fibble.org/archives/000508.html the bug was not present in BB versions less than 4.2.1, but I did not test this.
jo
14 December 2008 at 5:29 am
Hey
Can i not use the blackberry 8310 as a regular GPRS enabled phone device only.
I was told i cant browse the net or connect to googlemaps if i didnt use a blackberry plan from my telco.
gopalcj@gmail.com
may i request an email reply too
appreciate this