Software Developer

Sunday, July 27, 2008

My deskbar-applet plugin for XFCE

Here is what i have done a couple of weeks ago. Maybe someone can find it also suitable:
click here

How to share internet between smartphone (T-mobile MDA with windows 6) and linux (ubuntu)

There are 2 ways to do that.

First one is using USB.

a couple of simple steps for that:

1. install usb-rndis-lite tool

svn co https://synce.svn.sourceforge.net/svnroot/synce/trunk/usb-rndis-lite
cd usb-rndis-lite
make
sudo ./clean.sh
sudo make install

2. enable USB internet sharing in a smartphone
3. connect smartphone to your pc
4. probably you also need to do that:

sudo dhclient

to get the ip address

Also make sure that your activesync is not running on pocketPC- close it if it is started.

That's it for the first step.

Second one is using Bluetooth.

This one is more tricky.
I don't remember how did i do it exactly at the moment - but here the main steps:

1. install bluez-utils:
sudo apt-get install bluez-utils

2. then you need to enable bluetooth on your mobile phone and type in on your pc in a terminal:
hcitool inq

you should get something like :

Inquiring ...
00:17:83:80:DA:CB clock offset: 0x5426 class: 0x5a020c

the string
00:17:83:80:DA:CB
in your case should be different and this is the physical address of your mobile device.
3. create the file
/etc/bluetooth/pan/dev-up
with the contents:
#!/bin/bash 
ifup bnep0

and the file
/etc/bluetooth/pan/dev-down
with the contents:
#!/bin/bash 
ifdown bnep0

4. open
/etc/default/bluetooth
find the line with the
PAND_ENABLED=0
and change it to
PAND_ENABLED=1
Then find the line
PAND_OPTIONS=""
and change it to
PAND_OPTIONS="--listen --role=PANU --devup /etc/bluetooth/pan/dev-up --devdown /etc/bluetooth/pan/dev-down

5. enable bluetooth internet sharing on your mobile device and in terminal on PC type in:
sudo pand -c {your physical device address}

for the first time it will ask for the pin but afterwards it is not needed.
6. probably you will also need
sudo dhclient bnep0

P.S. sometimes it is needed to clean up the bluetooth pair devices on PC and mobile device. I also use
kbluetooth
for that.