Targeting multiple platforms with the cloud

This week’s MSDN Flash article is from fellow DPE colleague Martin Beeby who talks about the challenges of building mobile applications optimised for particular platform capabilities, a subject close to me heart. Anyway, I’ll let Martin explain (you can find him on Twitter at @thebeebs)…

Targeting multiple platforms with the cloud

The current state of the mobile market is fragmented; there are many different platforms, none of which will work on all mobile devices. Businesses are left to make a platform decision knowing that the wrong choice may exclude them from future market opportunities.

Different businesses are formulating different strategies. Some business are choosing to target one developer platform, some are choosing to develop only in-browser applications while others, to ensure maximum market coverage, are opting to adopt a graded support strategy.

Graded support is an acknowledgement that mobile phones have capabilities and features that are as unique and heterogeneous as their users. Users using different devices should expect different grades of experiences. Users with smarter devices should be able to use the capabilities of that device to receive a richer experience.

Imagine we are developing a graded support strategy for an online retailer, below is a matrix of the kind of experience we might want to deliver:

Grade C

WAP Phone

User should be able to browse and order from your site when online

Grade B

Java Applet or Gadget

Should be able to have a richer User Interface and benefit from reduced bandwidth as HTML and UI elements do not need to be downloaded from the cloud

Grade A

Smart Phone

Should be able to browse the catalogue even when offline and should be able to make orders that will be processed when the device regains connectivity.

By creating cloud services that are capable of supporting these various scenarios, it should be possible to write applications for the various platforms that are simple and similar and contain as little business logic as possible. Supporting a new platform should become a matter of developing a new UI layer that has graded levels of complexity.

In general the smarter a platform is, the less reliance it should have on being continuously connected to the cloud. Your business can choose its most important platforms based upon user demand or ease of development and should attempt to develop on these platforms to improve the offline ability.

There are three key abilities that can be implemented on smarter platforms:

Pre-caching and caching

Whilst a user is navigating your application the information they are accessing should be cached and information that might be relevant to them should be pre-cached in the background. This way if a user goes offline, perhaps on the tube, they should still be able to use your application.

Synchronisation

If you buy tickets for the cinema using your mobile you don’t want a drop in connectivity to get in the way of the purchase. It’s therefore important that the application can save the data and synchronise it back when a connection becomes available. It’s also probably a good idea to do as much of the complicated syncing logic in the cloud rather than on the device. You can find out more about how to do this here.

Sensors

Current mobile browsers only expose limited access to phone APIs like location. Support for accelerometer, vibration, compass or gestures can only really be provided by using the phones native application platforms. By supporting these features you can ensure your application feels like an integrated part of their phone. As browsers become more developed they will no doubt integrate better but it’s unlikely that any OS is going to allow web applications access to APIs such as vibration, imagine the coin rattling havoc that a maliciously crafted application could wreak.

By Investing and building services in the cloud that can serve all the different grades of applications you will be able to spend less money developing each application and therefore be able to target more platforms and reach a wider audience. Ramon Arjona shows you how to build a cloud connected application for Windows Phone 7 here.

To find out more about the different platforms currently available and how to get started developing for them, take a look at my blog where I’ve listed all of the platforms I’ve used or evaluated in the past 6 months.