Table of Contents
internet-access from linux-pc via bluetooth
I want to access the internet using the nokia e90 via bluetooth from a thinkpad running linux Debian unstable. Kernel with the bluetooth-parts at least as modules is required. The part for pin-authentication uses dbus now as backend, this was sdp-daemon bevore.
first time setup
first steps
- apt-get install bluez-utils pkg-config libdbus-1-dev minicom
- now activate bluetooth if needed, pressing <Fn>+<F5> does this on the thinkpad.
- hciconfig hci0 up
- killall hcid # stops the running hcid
- hcid -nds # execute in a terminal for debugging. If you get 'org.bluez not found' reboot the system.
- hciconfig -a # should show informations on your computers bluetooth-adapter now
- hcitool scan # now searches for bt-devices. If the nokia e90 is appropriately configured it can be seen here
- l2ping <bt-address> # now pinging should work, bt-address is the bluetooth-address of the nokia e90
- sdptool browse # browses the available services
- sdptool search DUN # this searches for the DialUpNetworking service, should be 'channel 2' at the e90
- Now we need an agent for the pin-handling, on Debian unstable it has to be compiled and then be started:
- cd /usr/share/doc/bluez-utils/examples
- zcat passkey-agent.c.gz >passkey-agent.c # lets keep the original file as its part of the bluez-utils package
- make # build the passkey-agent
- mv passkey-agent /usr/local/bin
- /usr/local/bin/passkey-agent --default 8342 # this starts the passkey-agent using 8342 as pin
serial connection over bluetooth
rfcomm connect 0 <bt-address> 2 # This starts the connection - the pin is now requested on the e90. You can now on the
# nokia e90 'authorize' the connection to be established without requesting the pin each time. I guess its just
# protected by the bluetooth-address of the device.
emacs /etc/bluetooth/rfcomm.conf # an entry for rfcomm0 gets created so accesses trigger the connectionin future
minicom session
Now run 'minicom' and configure /dev/rfcomm0 as serial line. Talk to the e90 executing 'ATZ' resets, 'AT+CGDCONT=1,,"internet.t-mobile"' and 'ATD*99***1#' should produce no errors and will result in a ppp-connection. If that works stop minicom. An Example-session:
Press CTRL-A Z for help on special keys AT S7=45 S0=0 L1 V1 X4 &c1 E1 Q0 OK ATZ OK AT+CGDCONT? +CGDCONT: 1,"IP",,,0,0 OK AT+CGDCONT=1,"IP","internet.t-mobile" OK ATD*99***1# CONNECT ~ÿ}#À!}!} } }
- http://www.xs4all.nl/~ernstagn/GPRS-HOWTO/GPRS-HOWTO-5.html - has some instructions for this
- http://www-dcg.fnal.gov/Net/HYSTRM20.TXT – has explanations on the hayes-commands
the chatfile
cat >/etc/ppp/chat_nokia_e90 <<EOT ABORT ERROR '' AT OK ATZ OK AT+CGDCONT=1,"IP","internet.t-mobile" OK ATD*99***1# CONNECT '' EOT # for other ISP than t-mobile you have to replace internet.t-mobile with the value from the e90 menu # tools->settings->connection->Access points->ISP-internet-entry->Access point name
the ppp-configfile
cat >/etc/ppp/peers/tmobilestart_nokia_e90 <<EOT noauth connect "/usr/sbin/chat -v -f /etc/ppp/chat_nokia_e90" debug /dev/rfcomm0 230400 defaultroute usepeerdns noipdefault crtscts noccp ipcp-accept-remote ipcp-accept-local EOT tail -f /var/log/messages & # lets look at the logfile pon tmobilestart_nokia_e90 # and lets dial in
daily usage
- Enable bluetooth on the e90, 'visible for all' is not needed any more
- Any access to /dev/rfcomm0 triggers establishment of the bluetooth-connection, so 'pon tmobilestart_nokia_e90' is all you need now.