Chris Auld, Intergen’s Chief Technology Officer, showed attendees how to develop connected, cross-platform mobile applications with Mono and Windows Azure.
With the abundance of mobile devices and operating systems in the market – including Apple’s iOS, Google’s Android, and Microsoft’s Windows Phone and upcoming Windows 8 – numerous opportunities are being created for organisations that want to create new applications or provide access to existing systems through a mobile device. Applications that work on a range of platforms is a goal for many organizations.
But where do you start? And what development options are available? How much more does it cost and which applications does it make economic sense for? How can one simplify the development and management of applications that work across multiple platforms?
Chris Auld, Intergen’s Chief Technology Officer, showed attendees how to develop connected, cross-platform mobile applications with Mono and Windows Azure. How to share code across Windows Phone, iPhone, Android, HTML5, and Windows 8, and better understand the realities of mobile development across these platforms.
2. WHY? MOBILE STRATEGY DISCUSSION HOW? MOBILE EXECUTION DISCUSSION
Why mobile matters? Value in unique user experiences
Types of mobile apps Cross platform options
By user class HTML+PhoneGap
By technology approach Mono
Why cross platform matters? Native x N
Does cross platform matter? Approaches to sharing code
Which platforms? Mono vs PhoneGap
When?
4. Why Mobile Matters
Does anyone in the room *not* have a smart device?
Anyone in your family 15yr-65yr *not* have one?
What did you use 1st today, PC or Smart Device?
How about last yesterday?
Have you used an app today?
6. Types of Mobile Apps
BY USER CLASS BY APPLICATION APPROACH
Enterprise Web Apps
- Field force etc. - It works
SME/BYOD - It’s optimized
- Expense claims etc. - ICBINB
Consumer ‘Real’ Apps
- Mobile banking - Wrapped HTML
- Native
7. Why Cross Platform Matters
Does it matter?
Does need for enterprise apps kill BYOD strategy?
Application Approach Extra Cost Extra Dev Capex Org Size for Break Even
Web App/Wrapped HTML 20% $50,000 250
X-Platform Toolkit (Mono) 30% $75,000 375
Full Native 70% $175,000 875
Assume: Enterprise app build of say $250k
Assume: BYOD strategy to save $200/device via co-pay
Assume: Three platforms ‘supported’ for BYOD
8. Why Cross Platform Matters
For Consumer/Public focussed apps it really does
matter.
iOS has massive penetration in high value user
segments
Android is bring Smart devices to the masses
Microsoft is playing catch-up, but, is prepared to buy
share
Think back to the first slide… how do you use mobile?
9. Which Platforms?
Market share?
Visitor share?
Your site?
Some other ‘common’ site?
You want to target, in priority order, the
platforms used by people most likely to use
their mobile devices to access your service
10. Which Platforms?
IRD GST Site
Want to support filing GST return from mobile device
Business users
Blackberry is still very popular with business users
Should we prioritize Blackberry? iOS?
11. Which Platforms?
How do app usage patterns differ?
Both Android and iPhone users D/L approx 10 apps
/month
19% of Android users buy at least one app /month
50% of iPhone users buy at least one app /month
*Admob Mobile Metrics
15. Cross Platform Mobile App Dev
HTML + PhoneGap Mono
• Significant reuse • C# + .NET in • Platform specific
Re-use web assets VS.NET UX
• Doesn’t look native • Can write highly
Lambdas, LINQ
Everything like iOS?
Delegates, Events optimized code
• AppStore issues • Games
• Rich
• X-Browser issues
communications • Graphics intensive
• No offline on WP7
• Access to almost all apps
• Animations poor • Write the app 3
platform APIs via
• APIs unavailable times
Mono Wrappers
• Hardware access • Go native if needed • 3 different
• Platform specific • UI still written ‘by- languages
• It’s Javascript hand’ • 3 x code to maintain
Must use OSS • Write UI for each • Objective C is awful
Less productive platform +ve&-ve
100% Shared Code 0% Shared Code
16. Shared Code with Mono
Shared files co-located; *.csproj for each platform
Each solution has
Platform specific project
Shared project
Similar MVVM pattern for all platforms
Shared Models
Shared Repository
May be able to share ViewModels
Can use shared Interface + Platform Specific Implementation
WindowsPhonePreferencesProvider: IDevicePreferencesProvider
Can use pre-processor directives
#if MONOTOUCH
Can support Windows Mobile easily. No support for Blackberry
17. Shared Code with PhoneGap
All files co-located
A solution has
General purpose HTML + HTML templates
Shared CSS + JS + Images
Platform specific CSS + JS + Images
Use MVVM or MVC pattern for all platforms
Backbone.js/Knockout.js
Share ‘everything’
Complexity increases as platform count increases
Each platform may require some specific shims
Windows Mobile not supported & Older Blackberry OS is very hard to support
Older phones may get a ‘bad’ experience
18. Choosing between PhoneGap or Mono
PHONEGAP MONO
Existing advanced HTML+JS skills Existing .NET C# dev skills
Must have MVVM/MVC Useful to have MVVM/MVC
knowledge knowledge
Existing web resources Complex communications
A need/desire to support browser requirements
based viewing Need lots of platform hooks
Communications layer REST ready Performance matters
More productivity up-front
The smaller your organization and project the
more developer productivity matters…
Mono represents a high productivity choice even for pure one platform plays
19. Guidance By Intergen
Intergen staff have been involved in developing several reference
applications that are freely downloadable in source code form
Project Silk http://silk.codeplex.com/ (Don Smith AKL)
Rich HTML+JS Web Apps.
Project Liike http://liike.github.com (Don Smith AKL)
Rich HTML+JS Mobile Web Apps.
StockTrader v6 https://azurestocktrader.cloudapp.net/
(Chris Auld/James Carpinter WLG + others)
Massive scale Azure based app with cross platform rich client for
iOS, Android, WP7, HTML5+JS, Windows Metro (Mono based)
20. Mobile Matters – Mobile First
Do you *really* need x-platform
Phone + Mono both useful options