Android Development for . NET / C # Developers with Mono for ...

fansbutterflyMobile - Wireless

Jul 19, 2012 (5 years and 2 months ago)

668 views

Android Development for .NET/C#
Developers with
Mono for Android
Wallace B. (Wally) McClure (aka “.NET Judas”)
Scalable Development, Inc.
http://www.morewally.com/
http://www.scalabledevelopment.com/
Twitter: @
wbm
Who am I?

“Professional Android Programming with Mono
for Android and .NET/C#”

Summer 2011.

Visual Studio Magazine Article.

“iPhone
Apps for the .NET Developer”

Ebook
.

Print
book.

“Beginning AJAX with ASP.NET”

“Beginning ASP.NET 2.0 AJAX


MVP

ASP.NET.

ASPInsider
.

ASP.NET Podcast
.
Mileage May Vary

Have a Heart
My mobile history

Mobile is a twinkle in my eye.

“Mobile doesn’t sell.”

Early 2009.

Cloud application.

Convinced that needed to be on the iPhone.

How?

Looked at alternatives.

MonoTouch.

Apple
iPhone SDK
missteps.

Hey there’s the Android thing taking off.

Wow, there’s huge growth in Android.
Android History

2005

Google purchases Android, Inc.

2007

OHA announced.

Fall 2008

1.0 SDK ships.

2009

Various updated SDKs.

Summer 2009

MonoTouch.

2010

Momentum grows significantly.

Winter 2010

Mono for Android Announcement.

April 2011

Mono for Android 1.0.
Where are we at?

Increasingly mobile.

Laptops are not quite convenient.

Power management is important.

Wifi
is not everywhere
.

Multiple smartphone platforms.

iPhone
has tremendous mindshare/
marketshare
.

Android has seen tremendous growth.

RIM is dominant in the corporate market.

Windows Phone 7 has shipped.

.NET Framework is
a popular framework
.
Mobile Development Issues

Battery.

Screen Size.

CPU.

Memory.

Development Tools.

Using Existing Knowledge.
Why Android
What is
Mono for Android?

Mono

Open Source implementation of .NET.

Mono for Android is
a .NET/c# layer over
native APIs.

Visual Studio

IDE.

No
Design Surface.
Architecture / Architecture
Why Mono for Android?
Devices/Technology

Android.

Growth rates

.NET

Market Share
.

Existing Knowledge.

Mono

Cross Platform.

Maturity
.
Developer

Visual Studio Ecosystem.

Source Control.

Plugins.

Languages.

C#.

Others in the future.

Your existing knowledge!

Some level of
compat
with MonoTouch.
Current Status

Mono/
MonoDevelop
are
released products.

Mono for Android 1.0 has
been released.

2
-
3 week updates.
Code on my system
:

Android
2.3 SDK.

Visual Studio 2010.

Mono for Android
plugin.

Java.

Eclipse 3.6.

DroidDraw.
What
Mono for Android
is Not

Not
Winforms
/WPF on
Android.

Not
a cross
-
platform/cross
-
compiler tool.

“.NET is (Southern)American English.
Mono for
Android
is British English. C# is the common bond to
learn the customs (programming
idiosyncracies
) of
Android.”
How do the users get the Framework?

Embedded with your app.

Standalone.
What about Silverlight?
Editions

Trial
-
“Community”

Free.

Simulator

Can’t deploy to device.

Student.

Single
User.

Enterprise
.
Runtime Concept
Let’s Get Started with
Mono for Android!
Terms

Activity.

Resources.

Intent.

PendingIntent
.

BroadcastReceiver
.
Create a
N
ew Project
Project
Resources

UI.

Images.

Defined strings.

Icons.

Resource.Designer.cs
Code

Activity.

Application.

Attributes.

Load UI.

Setup Controls.

Events.
Design Surface

Visual Studio features a really great design surface.

ASP.NET.

Winforms
.

No design surface for Mono for Android 1.0.

Intellisense.

XML based layout language.

DroidDraw.

Eclipse Plugin.
Emulator

Its Horrible!!!!!!!!!!!!!!!

Speed performance.

Snapshots.

Keyboard.

Location.
Hey, Your Apps are Big!

Linker

Only what you need.

Two ways to ship.

Runtime Embedded

default.

Stand alone.
Debugging

ADB.

DDMS.

Visual Studio Debugging.

BreakPoints
.

Emulator
Settings
-
http://
bit.ly/ghU7E0

no
-
boot
-
anim.

Snapshots.
Projects to Review

UiNicities
.

Sensors.
Resources

http
://Mono
-
Android.Net/
.

https://
github.com/mono/
monodroid
-
samples/

Reto
Meier

Pro Android 2 by
Wrox
.

http://morewally.com/
.

http://redth.info/
.

Good
examples online.

Twitter
hashtag
:
#MonoDroid

IRC channel
.
Cross Platform
-
MDr
, MT, WP7

Mono for Android
-
Growth Rates.

MonoTouch
-
$ volume.

Windows Phone 7
-
.NET/Silverlight.

Problem.

Various UIs.

Integrate .NET logic.
Strategy

Separate UI / Logic projects.

Logic
-
.NET only.

Graphic UI libraries

OpenGL.

Delta Engine.
What we’ve done

Short Introduction to Android.

Walked through the Mono for Android
plugin.

Deployed an App.

Debugged.

Caveats.
Thanks!

You.

The entire Mono Team.

Miguel D.
Icaza
.

Joseph Hill.

Jon Pryor.

Jonathan Pobst
.

Robert “Bob” Elliott.

Jim
Minatel
.

Wiley Publishing.

A great set of co
-
authors.

A great set of tech editors.