android wear applications in c# with xamarin

35
Developing Android Wear Apps in C# James Montemagno Developer Evangelist, Xamarin @JamesMontemagno

Upload: james-montemagno

Post on 28-Nov-2014

525 views

Category:

Engineering


11 download

DESCRIPTION

With the introduction of Google's Android Wear, you are no longer restricted to just phones and tablets when it comes to developing great Android apps. You want notifications on your wrist? You got it. You want to run an app on your wrist? You got it. Xamarin lets you create iOS, Android, Mac, and Windows apps from a shared C# code base and that means C# code will be running on your wrist. In this session, let me take you through the awesome new features of Android Wear and the tools required to start building the apps you want for Wear. We'll extend a current app with rich notifications and even create a brand new app from scratch live on stage that runs right on your Android Wear device.

TRANSCRIPT

Page 1: Android Wear Applications in C# with Xamarin

Developing Android Wear !Apps in C#!

James Montemagno!Developer Evangelist, Xamarin!@JamesMontemagno!

Page 2: Android Wear Applications in C# with Xamarin

Who is this guy?!

James Montemagno!Developer Evangelist, Xamarin!

@JamesMontemagno !!http://motzcod.es!

MyStepCounterApp.com!

Page 3: Android Wear Applications in C# with Xamarin

What is Xamarin?!

Page 4: Android Wear Applications in C# with Xamarin

Automatically test your app on!hundreds of mobile devices !

Create native iOS, Android, Mac and Windows apps in Visual Studio and C#

Page 5: Android Wear Applications in C# with Xamarin

Xamarin’s Unique Approach!

Native With !Code Sharing!

Page 6: Android Wear Applications in C# with Xamarin

Anything you can do in Objective-C, Swift, or Java !can be done in C# with Xamarin using Visual Studio!

Page 7: Android Wear Applications in C# with Xamarin

What is a wearable?!

Page 8: Android Wear Applications in C# with Xamarin
Page 9: Android Wear Applications in C# with Xamarin
Page 10: Android Wear Applications in C# with Xamarin
Page 11: Android Wear Applications in C# with Xamarin

Current Wearables!

Page 12: Android Wear Applications in C# with Xamarin

LG G Watch!§  Reference Device!§  $180!§  9 axis Sensor!§  Accelerometer!§  Compass!§  Gryo!

!

Page 13: Android Wear Applications in C# with Xamarin

Samsung Gear Live!§  Consumer Device !§  $200!§  Sensors:!§  Accelerometer!§  Digital Compass!§  Gyroscope!§  Heart rate monitor!

Page 14: Android Wear Applications in C# with Xamarin

Moto 360!§  First Circular Device !§  $250!§  Sensors:!§  Pedometer (9-axis)!§  Ambient Light!§  Optical Heart Rate!

Page 15: Android Wear Applications in C# with Xamarin

Why You Should Care!

Page 16: Android Wear Applications in C# with Xamarin
Page 17: Android Wear Applications in C# with Xamarin

How they work!

Page 18: Android Wear Applications in C# with Xamarin

Bluetooth 4.0 Low Energy!§  Used for all communication!

Page 19: Android Wear Applications in C# with Xamarin

Android Phone Required!!§  Android 4.3+!§  Android Wear App !§  Bluetooth LE Required!§  http://g.co/WearCheck!

Page 20: Android Wear Applications in C# with Xamarin

Android Wear!§  Android 4.4W (based of KitKat)!§  No Access To:!§  Android.Webkit!§  Android.Print!§  Android.App.Backup!§  Android.AppWidget!§  Android.Hardware.Usb!

§  Sensor Support!§  Call HasSystemFeature() before using API!

Page 21: Android Wear Applications in C# with Xamarin

!Notifications!Wear Specific Apps!Companion Apps!!

Page 22: Android Wear Applications in C# with Xamarin

Notifications!

Page 23: Android Wear Applications in C# with Xamarin

Notifications - Actions!

Page 24: Android Wear Applications in C# with Xamarin

§ Custom Actions § Voice Input §  Inbox Style Card

Notifications – Extended

http://www.nuget.org/packages/Xamarin.Android.Support.V4/

Page 25: Android Wear Applications in C# with Xamarin

Demo!

Page 26: Android Wear Applications in C# with Xamarin

§ Companion App •  Android app that runs on a wearable

§ New Themes § New UI Widgets •  BoxInsetLayout •  CircledImageView •  WearableListView •  More…

Android Wear – Building Apps

http://www.nuget.org/packages/Xamarin.Android.Wear/

Page 27: Android Wear Applications in C# with Xamarin
Page 28: Android Wear Applications in C# with Xamarin

Demo!

Page 29: Android Wear Applications in C# with Xamarin

Android Wear – Sync Data

http://www.nuget.org/packages/Xamarin.GooglePlayServicesJellyBean/

§  Exposed via Google Play Services •  Data API

o  Sync datastore between phone and wearable § Message API

o  Send small payloads and simple o  communication

Page 30: Android Wear Applications in C# with Xamarin

Sync Data!

Page 31: Android Wear Applications in C# with Xamarin

Demo!

Page 32: Android Wear Applications in C# with Xamarin

Resources!§  Tips for Your First Wear App!§  http://blog.xamarin.com/tips-for-your-first-android-wear-app/!!§  Google Documentation!§  http://developer.android.com/training/building-wearables.html!!§  Samples!§  http://developer.xamarin.com/samples/android/Android%20Wear/!!!!

Page 33: Android Wear Applications in C# with Xamarin

Seattle Mobile .NET Developers Group!

Meetup.com/SeattleMobileDevelopers!Location: City University (6th and Wall)!

Next Meetup: October 14th !Topic: What’s new in iOS 8 and Android L !

Page 34: Android Wear Applications in C# with Xamarin

Get Started Today: xamarin.com/download!

Page 35: Android Wear Applications in C# with Xamarin

Q & A!!Get your free C# t-shirt:!xamarin.com/shirt!

Find Me:!@JamesMontemagno | @XamarinHQ!http://motzcod.es | http://blog.xamarin.com!