Experimental Bluetooth on Puppy

This is experimental, OK? I'm sure there are much better ways to do it, but for now it seems to work for gprs connection (my settings: puppy 2.13 running on hp pavilion zv6278ea with integrated bluetooth module, plus a gprs-enabled nokia 9500 phone equipped with a Wind sim card).

Everyone is invited to contribute so that in the end we can have full bluetooth on puppy :-)

First, really really thanks a lot to daemon who discovered that old bluez-utils have fewer dependencies and may work on unmodified puppy: here on the forums.

What follows comes almost entirely from http://www.artm-friends.at/rm/bluetooth-gprs-rm-HOWTO.txt

Before all, do you have a gprs profile for your ppp connection? If you have it, good, otherwise you may adapt mine to your phone. I cannot help you in this task, just search on the internet or ask your telco. My profile, good for the Italian provider Wind, is made of two files, i.e.

"" "ATZ"
OK 'AT+cgdcont=1,"IP","internet.wind"'
OK ATD*99* * *1#

(Attention, in the 11th line there should be no space between the 3 asterisks so please cancel those spaces. The wiki does not allow two asterisks without spaces between!)


connect "/usr/sbin/chat -v -f /etc/ppp/chatscripts/gprs"

This is enough to connect.

Where do you find the required info for connecting to your provider? Try
http://www.gprsec.hu/modules/providers/ or
http://www.reqwireless.com/apns.html or
http://www.hzmi.com/forums/viewtopic.php?t=104 or
http://www.taniwha.org.uk/gprs.html or
or ask your telco!

Back to daemon's intuition!
I took his tgz's, compiled and made a dotpup which you can get from my site. Install it - you won't find any new program in your menu so no need to restart jwm - but they will give you all the files needed.

Done? OK

First phase you have to determine the mac address and the dial-up networking channel for your gprs-enabled phone.

[corrected from previous version] The default modules setup for puppy 2.13 does not include some that are necessary for our task. So go get them
here on the forums or here from my site for the kernel. In the previous version of this guide I erroneously stated they were available without downloading. Install the dotpup and go on.

Open a terminal and insert the needed modules:
modprobe bluetooth
modprobe l2cap
modprobe rfcomm
modprobe hci_usb

Now start the hci daemon:

And go looking for your gprs phone, turned on and ready for connection (you have one, don't you? :-)

hcitool scan

you expect to get something like this on your terminal:
Scanning ...
00:0E:ED:AE:D7:3B EdB

The first six hexadecimals are the mac address of your phone, then comes the name you gave it or its default name. Copy somewhere the address.

Then, we are looking for your phone's channel enabled to dial-up networking. Give this command (of course put the mac address of your phone in the place of mine):

sdptool browse 00:0E:ED:AE:D7:3B

and you should get a long listing of the capabilities of your phone, including something like that:

Service Name: Dial-Up Networking
Service RecHandle: 0x10008
Service Class ID List:
"Dialup Networking" (0x1103)
Protocol Descriptor List:
"L2CAP" (0x0100)
"RFCOMM" (0x0003)
Channel: 2
Language Base Attr List:
code_ISO639: 0x454e
encoding: 0x6a
base_offset: 0x100
Profile Descriptor List:
"Dialup Networking" (0x1103)
Version: 0x0100

Well, now you know you have a dial-up networking-enabled phone, and that works on channel no. 2 (8th row of the above output).

Now you have the needed data to do your connection: mac address and dun channel number.

The experimental script is the following (it may be changed in time to get more features):


modprobe bluetooth
modprobe l2cap
modprobe rfcomm
modprobe hci_usb

mknod -m 666 /dev/rfcomm0 c 216 0


# in the following line change mac address and channel number for your phone
rfcomm bind /dev/rfcomm0 00:0E:ED:AE:D7:3B 2

rxvt -bg "light yellow" -geometry 134x20 -title GPRS_connection_tail -e tail -n 20 -f /var/log/messages &

pppd call gprs

gxmessage -center -bg "light green" -title "PPPD calling..." -buttons "EXIT" "PPPD calling...
press EXIT for exiting GPRS connection"

killall pppd
rfcomm release /dev/rfcomm0
killall rfcomm
killall hcid
kill $(ps|grep GPRS_co)


You have to change the mac address and channel we determined in the steps before according to your phone's features.

The script will open a terminal where you can monitor the connection to your phone, and a small window to quit your connection.
You will be ready for opening your browser or doing other internet activities when the lines stop scrolling and you see something like the following:

Jan 23 11:33:31 (none) daemon.notice pppd[10936]: local IP address
Jan 23 11:33:31 (none) daemon.notice pppd[10936]: remote IP address
Jan 23 11:33:31 (none) daemon.notice pppd[10936]: primary DNS address
Jan 23 11:33:31 (none) daemon.notice pppd[10936]: secondary DNS address

indicating that you have received an IP and DNS numbers from your telco.

If instead the lines stop on an exit command, it means your phone could not hook the gprs signal and you have to EXIT through the open window and start over. (Or, might be there is some other problems I haven't figured out yet!)

Also See

There are no comments on this page.
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki