Portrait of Edd Dumbill, taken by Giles Turnbull

Subscribe to updates

Feed icon Atom or RSS

or get email updates

What I make

expectnation
a conference management web application


XTech Conference
a European web technology conference

Synchronizing a P800 with Evolution

Finally I've achieved a long-held goal: clean and functional synchronization between my GNOME desktop and my Sony Ericsson P800 phone.

Here's what to do. Beware, this is not pretty.

Grab Multisync. I'm using a 2003/10/14 CVS snapshot. I imagine that the 0.80 official release should work as well.

First, you must figure out how to set up a TCP/IP connection over PPP between your P800 and your desktop running Multisync. There are several ways you can do this:

  • use your GPRS connection and ensure your Multisync is available on port 5079 through your firewall. (Least preferred option, as it means paying your cellphone provider for data transfer.)
  • use your USB cradle and the right kernel module to present the cradle as a serial port on your Linux box. Details of how to do this are documented on Stian Jordet's site.
  • use a Bluetooth connection.

Because I'm a wireless freak, I'm pursuing the Bluetooth option. Here's what I did:

  • set up an rfcomm port connected to the "Serial Port" channel on your P800. This may change. Use sdptool to find out where it is. I've connected /dev/rfcomm10 to this port.
  • run dund (from BlueZ bluez-pan), with the following (or similar) options:
         dund --listen --persist --channel 3 noauth debug crtscts \
            lock local proxyarp passive ipcp-accept-local \
            ipcp-accept-remote ms-dns $DNS_SERVER \
            $PC_ADDR:$P800_ADDR
    
  • Configure IP addresses and DNS properly. I have PC_ADDR=192.168.7.68 and P800_ADDR=192.168.7.1 and DNS_SERVER set to my local DNS server. The DNS server should have an entry for the host wsockhost.mrouter which is the same as PC_ADDR. If your DNS server isn't the same machine as PC_ADDR be sure to put in a route so it can route back to the 192.168.7.0 network (or whichever network you choose.)
  • Advertise the PPP service as a serial port, with:
        sdptool add --channnel=3 SP
    
  • To switch on the PPP connection, you need to "poke" the P800. I do echo >/dev/rfcomm10. Then the P800 reconnects back to my PC and runs the PPP connection. You can see it happening in /var/log/syslog.

With me so far? If not, practice getting this bit working.

I've found that old, crusty Evolution addressbooks and old, crusty P800 addressbooks (and same for calendars) do not merge well together. By "not well," I mean that Multisync or the P800, or both, end up crashing and you end up in a mess.

I've had the best results when both sides start with a blank state. So, this is a good time to back up your P800, and your Evolution.

With the P800, you can do this for the addressbook by "Send this folder" and beaming the addressbook somewhere. You end up with an All.vcf file. Hang on to this, you can use it later. For the contacts, the P800 stores these in a file in C:\Documents\Agenda, so it's easier to back up to a memory stick or somewhere.

Now it's time to delete your P800 contacts. I did this with the excellent (and free) Contacts Control program. Also, delete your P800 calendar items by removing the file from C:\Documents\Agenda. (To be safe, do this from a fresh restart of your P800 so neither the calendar or addressbook applications are running.)

By now, you should have an empty Evolution and an empty P800. Establish the TCP/IP connection between your PC and the P800, and fire up Multisync. Add a synchronization pair between Evolution and a SyncML: set up your SyncML in a server configuration, using straight http.

Now start the "Remote Sync" app on your P800. In "Preferences" configure the server address as http://PC_ADDR:5079 (using the address you chose for your PC). Configure the username and password to be the same as you chose in the previous step in Multisync.

Then configure the Calendar/Tasks sync task. Set the server database to be calendar (lower case) and enable it. Do the same for the Contacts task, setting the server database to be addressbook.

OK, you should be ready to rock. Hit the "Sync" button on the P800 and pray.

All being well, the synchronization should succeed. Now you can start playing by adding in test entries in Evolution or the P800, and hitting sync on the P800 again.

Now it's time to restore your data. Beam the All.vcf file back to your P800, and save all the entries back to your addressbook. Then synchronize, and watch them magically appear in Evolution. There's no especially speedy way of doing calendar entries I know of, so it's a manual job I'm afraid.

One odd note: contacts from Evolution go a bit strange in the P800. This is because Evolution stores addresses in two ways: in separate fields, but also in a "label" format. So when you look at the contact in the P800 you see the address repeated. The best thing is not to worry about it.

Conclusion

This should be a lot easier than it is.

In my opinion, Sony Ericsson made a big mistake in not supporting the older synchronization standard, IrMC, on the P800. It would have removed the need for all the TCP/IP and SyncML silliness.

Still, it works, and I am happy.

blog comments powered by Disqus


You are reading the weblog of Edd Dumbill, writer, programmer, entrepreneur and free software advocate.
Copyright © 2000-2012 Edd Dumbill