Gentoo Wiki


I'm writing this so that others can benefit from the things I've learnt during my painful attempt to set up my Sony Ericsson P910 with bluetooth:
Article by Richard Hamnett:


Installing bluetooth support

I am going to assume that you already have a working bluetooth stack.
If you need help with this please visit Mobile Phone/Bluetooth.

Sync your P800/P900/P910's calendar and address book with Evolution

Install multisync with evolution plugin

Add 'evo' to the app-pda/multisync use flags:
# echo "app-pda/multisync evo" >> /etc/portage/package.use
Emerge multisync:
# emerge multisync

Connect up your mobile phone's serial port

First of all we need to fire up bluetooth:
# /etc/init.d/bluetooth start
To connect to the phone, we need to find out which of it's channels is the serial port. To do this we can use the following commands:
# hcitool scan
This will return the MAC addresses of the phones in range. Make a note of yours. It will look something like 00:0F:DE:F2:0C:4E:
To find the serial port channel from your phone we must then use sdptool to list the available services, and make a note of the Serial Port channel number:
# sdptool browse 00:0F:DE:F2:0C:AC #change this to your MAC address

Create a DNS host record for wsockhost.mrouter

I found this next part out the hard way. When the bluetooth serial port is connected, these Pxxx smart phones expect to be able to resolve a host "wsockhost.mrouter" through the connection. The phone will check that this resolves every 2 to remain connected, we need to be able to provide a resolution to this DNS request from the PC we are connecting from:
I am certain that there are easier ways to do this....but for simplicities sake, I am going to show you how to do it using BIND 9:
# emerge bind
Tell bind to listen on all interfaces. Edit /etc/bind/named.conf by chaning the listen-on value to:
listen-on { any; };
NOTE The semi colon inside the brackets:
Add the following into the /etc/bind/named.conf file:
zone "mrouter" {
       type master;
       notify no;
       file "mrouter";
Now create the record we are going to use for the resolution by creating the file /var/bind/mrouter:
$TTL 86400
@ IN SOA ns.mrouter root.mrouter (
 86400 )
     NS ns.mrouter.
ns A
wsockhost A
NOTE: Make sure that the lines 1,2 and 9,10 are at the beginning of the lines, with NO SPACES:
We don't need to start bind yet:

Create the DUND connection listener

Now we configure the Bluez Dialup Neworking Daemon to listen out for connections on our serial port and automatically fire up pppd when one is detected:
# dund --listen --persist --channel 3 noauth debug crtscts 460800 lock \
local proxyarp passive ipcp-accept-local \ 
ipcp-accept-remote ms-dns
NOTE: Will be your PC's address, and will be the IP address of the actual phone. DO NOT FORGET TO CHANGE THE CHANNEL to your phone's serial port channel that sdptool returned. MAKE SURE ppp module is loaded too
Now we need to bind an rfcomm port to the phone's serial port channel:
# rfcomm bind 1 00:0F:DE:F2:0C:AC 3
NOTE: You must change the MAC address and the "3" at the end to your phones MAC and the phones serial port channel we found from sdptool:
This will now have bound the connection to the device node /dev/rfcomm1 which we will use below to start the connection:
Now we just need to tell the system that channel 3 is a bluetooth serial port. Again note that you must change the 3 to the value of your phones serial port channel:
# sdptool add --channel=3 SP
The next step is very important! It took me a while to realise two things:
Firstly, you must not have KBLUETOOTHD running, as it intercepts the serial port connection request::
Secondly, you must make sure to start bind AFTER the pppd connection was successful and it prints the new local and remote IP addresses into the system log. You can find this by typing "tail -f /var/log/messages" in a new window root console, when you start the connection below::
Open a new terminal window, and watch the messages output:
# tail -f /var/log/messages
OK so now we fire up the connection by sending a 'poke' to the rfcomm port:
# echo > /dev/rfcomm1
This should return to the next line if successful without any output. You will see in the message log that the connection will initiate, and it should print the new loca and remote IP addresses:
It is now imperative that you start BIND as soon as possible, because the phone will be starting to try to resolve the wsockhost.mrouter domain:
# /etc/init.d/named start
This will now keep the serial port connection open as long as you want. This is actually the main stumbling block that most people I have ever talked to about connecting a P800/900/910 serial port:

Configuring MultiSync

Launch multisync
# multisync
Create a new syncronisation Pair
First plugin: Evolution 2 - Options
Check calendar and addressbook further down
Second plugin: SyncML:
SyncMl Role - Accept connections
Choose HTTP not HTTPS
Enter a username/pass
Options tab - Select both options
Launch evolution (i think it must be running for the plugins to work)

Configure the P910

Go into 'Remote Sync'
Edit -> Preferences
Server Address enter is the IP of your PC described in the DUND step::
Username/pass self explanitory - enter the user/pass that you put into multisync

Press done
If you want to sync the calendar, click it and make sure the server database is set to 'calendar' in LOWER case:
If you want to sync the Contacts click it and make sure the server database is set to 'addressbook' in LOWER case
Finally, press sync...and there you have it!!

I hope this article has been useful, please make sure that you edit any mistakes in the steps I have listed, as I've written this pretty much from memory

Retrieved from ""

Last modified: Sat, 30 Aug 2008 18:55:00 +0000 Hits: 3,566