Sunday, 13 January 2013

M25: My First WP8 App - Part II

For anyone considering developing a mobile app, whether for WP or others, I think having a well-defined purpose is the first step.  After all, the app is supposed to do something, right?  I may be stating the obvious, but there are some subtleties here worth recognising.  Initially I wanted to incorporate real-time traffic speed, CCTV cameras, Twitter feeds, etc.  While these are perfectly valid features, including them in the first cut may not fit in my timeline.  So, I stripped things down to the basics, which included:

  • Pull down current traffic information
  • Pull down known planned events related to the M25
  • Allow the user to define routes
  • Display status information
  • Use a background agent to display current data in a Live Tile

So, this was my list of core functionality or deliverables.  Regardless of any extra bells and whistles, the app had to solidly deliver this set of features.  As well as naming those items "to do", you should also be aware of what "not to do".  I set a personal target to get this done within the month of December.  Given my time constraints I felt this was doable.  A lot of the other ideas I had are still valid, but can be added to my roadmap for future versions.

I created a new solution in Visual Studio 2012.  To my solution I added a Windows Phone application targeting Windows Phone 8.0 called M25.WP8; a Windows Phone class library called M25.Data; and a Windows Phone Scheduled Task Agent called M25.Agent.

I knew from my feature set that this was the minimal architectural requirements.  M25.Data would do all the data management and processing.  While the M25.WP8 phone application tended to the UI/UX requirements and M25.Agent was dedicated to running in the background and updating the Live Tile.  Not shown in the diagram is the reference between M25.Agent and M25.WP8; to get your Task Agent to be recognised by Windows Phone it has to be associated with an application so it gets included in your xap.  Pretty straightforward.


No comments: