AirInformation Blog

Keeping technology fun

Posts Tagged ‘sync

Android iCal parser

with 6 comments

Testing on the parser is going well as you can see by the screenshot to the left. Although the app currently exists only as a test harness it will be used to test each component and aspect of the iCal sync service.

You can see that the iCal information is coming from a Zimbra Collaboration Server. The ics datastream includes events defined in three timezones (with two seemingly similar ones). It also contains 94 events; some of which date back to 2007 in this particular calendar.

The eventual sync app will be designed to filter out events that don’t feature within a current time window (maybe today + 7/14/30 days). Why a time window? Well, I have a feeling that this may be required in order to reduce the amount of work that the app has to perform each sync – if you can discard redundant events without having to process them that has to be good, no?

As far as I can work out, the steps to get to a working ical sync app or background service are:

  • get the ics (iCal) file from a remote server
  • support self-signed certificates
  • handle timezone conversions for event entries (see below)
  • write events from the ics file into the Android calendar
  • develop a synchronisation algorithm between the ics source and the internal calendar
  • provide a configuration activity to create, edit and remove calendars
  • support different schedules and modes for synchronization
  • deal with recurring events
  • … and whatever else I haven’t yet foreseen!

I’m currently working on converting event date/times between timezones and UTC. iCal event entries are (normally) stored in their local timezone whereas Android calendar entries appear to be stored in UTC (universal coordinated time).

Written by airinformation

February 21, 2010 at 9:05 pm

Posted in Android, development

Tagged with , , , ,

Keeping things in sync with Dropbox

leave a comment »

DropboxIf you haven’t heard of Dropbox, then you’ve probably been living under a shell for the past year. Dropbox is a cloud-based service that syncs folders on your computer(s) via its servers in the cloud.

You can use it to:

  1. backup your important files
  2. see the same view of your files on different computers
  3. shares files and folders (privately or publicly)
  4. see and edit previous versions of saved documents


Once you start using Dropbox, you’ll wonder how you ever managed without it. I know that this is a pretty bold claim but I’ll explain how it works for me.

I use a laptop when working at clients but need the same view of my documents and files when back at the office. Dropbox allows me to do this and keep my files in sync in real-time. As I create and edit a document on my laptop, the same document with the latest changes is (immediately) available on my office computer. When I make changes in the office, those changes are also available on my laptop when I next fire it up.

How this achieved?

On each computer where you install Dropbox, you create a Dropbox folder. This is a normal folder which is just like any other on your computer. What’s magical about it is that the Dropbox client software keeps this folder in sync with the Dropbox service in the cloud whenever you’re connected to the internet… and it does the same for all your other computers linked to the same account.

Unlike a networked or shared volume which is no longer available when you’re not connected to the network or internet, the files and folders in your Dropbox folder still exist when you’re not connected. The next time you connect, they re-sync again automagically! Dropbox also keeps versions of your document changes for the past 30 days. Wonderful if you need to see or restore a previous version.

All you need to do is go Dropbox and sign up for a free account. Then you install the software on each of your computers – they have versions available for Windows, Mac and Linux… oh and iPhone.

When you sign up for Dropbox you get 2Gb of free storage. If you refer friends and colleagues you can get up to another 3Gb free (250Mb for each referral). They also offer a paid for service which gives you lots more storage if you intend backing up your photos, music or video files.

What’s amazing about Dropbox is that it just works. Try it, you’ll never look back.

Disclaimer: I am in no way affiliated with Dropbox. There are two alternate services that I know of which may also be of interest to you; Sugarsync and SpiderOak.

Written by airinformation

February 20, 2010 at 10:40 am

Posted in security

Tagged with , ,

No ical support on Android… What was Google thinking?!

with 2 comments

This comment from the Android issues list really sums up the situation:

For being such a technically advanced platform, this oversight is laughable. iPhone OS
3.0 does this so beautifully, I was downright embarrassed when I discovered my brand-
spankin'-new Nexus One didn't support CalDAV. I have numerous Google Apps
domains, as well as Zimbra servers, that I use with my iPhone, calendaring to the
fullest. We need this BUILT INTO THE OS as a basic function.

Now why is such a critical feature missing from Android?

I have a theory that …

It’s just low down on Google’s priority list because Google feels that users can should must be forced to use Google’s calendar services to subscribe to remote ical services and then sync those calendars with the phone.

As you can see from this issue on Google, this just isn’t an option for some users, especially business users who cannot have their data accessible to Google.

I have been researching ical and caldav, and believe that it should be possible to create a background service that syncs remote (non-Google calendars) on an Android handset.

It looks as though it is also possible to create, delete and update calendars (and events) via the calendar content provider even though it is still relatively undocumented.

Through a preference activity the user could choose which calendars to sync to remote ical servers, to create new calendars and to associate colours with the (new or existing) calendars.

I think that the first stage would be to support read of remote calendars (ical), and once that is working to support remote updates (caldav) too.

If anyone is interested in collaborating on this, leave a comment with some contact details and I’ll come back to you.

This is an issue that seriously need sorting out and quickly!

** UPDATE ** As yet I haven’t received any offers of help but I have started to build the ical/ics sync on my own – you can keep abreast of its progress via this blog.

Written by airinformation

February 7, 2010 at 7:45 pm

Posted in Android, ical

Tagged with , , ,