Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Developing with Android Wear - next must have gadget

Developing with Android Wear - next must have gadget

Get to know
- What is Android Wear
- How to start developing for Android wear
- Breach the Un-breachable with Android wear V2.0 preview

Devavrata Sharma

August 01, 2016
Tweet

Other Decks in Programming

Transcript

  1. Developing for Android Wear By : Devavrata Sharma

  2. Agenda : - Introduction - Walkthrough with Android wear -

    Setup the environment - Development for Android wear - Packaging of the app for publishing - Do’s and Don’ts - What all new in Android wear 2.0 - Q&A
  3. Introduction - Emerging market of wear technology and devices with

    $8 billion and more - Concentrated traffic from Notifications - Helps you to do better time management.
  4. Major players are Motorola, LG, Samsung, Sony, Fossil, Asus and

    Tag Heuer
  5. Walkthrough with Android wear - Android wear design Majors -

    How the wear app gets installed on you the device. -How to interact with Android wear device -Swipe gestures -Voice commands
  6. Android wear design majors : - Suggest - context stream

  7. Android wear design majors : - Demand - The Cue

    cards
  8. None
  9. None
  10. Setup the Environment -Update your SDK tools to version 23.0.0

    or higher - Update your SDK with Android 4.4W.2 (API 20) or higher - Setup an Android wear virtual device or Android wear device - Download Android wear app from Play store on your phone - Command to connect phone with Android wear virtual device adb -d forward tcp:5601 tcp:5601
  11. App development for Android wear - Showing notifications - Extending

    actions only for wearable - Android wear specific app
  12. Notifications : final int notificationId = 1; final NotificationCompat.Builder notificationBuilder

    = new NotificationCompat.Builder(this) .setSmallIcon(R.mipmap.ic_launcher) .setContentTitle("Hello Wearable!") .setContentText("Sample text"); NotificationManagerCompat.from(context).notify(notificationId,notificationBuilder.build());
  13. Notifications :

  14. Notification with wearable functionalities : - Wearable only actions -

    Voice Commands - Extra pages
  15. Wearable only actions: final NotificationCompat.WearableExtender wearableExtender = new NotificationCompat.WearableExtender(); wearableExtender.addAction(new

    NotificationCompat.Action(R.drawable. ic_navigation,"Nearest Shop", navigationIntent)); notificationBuilder.extend(wearableExtender);
  16. None
  17. Voice Commands: final RemoteInput remoteInput = new RemoteInput.Builder (EXTRA_VOICE_REPLY).setLabel("Pls give

    feedback").setChoices(this. getResources().getStringArray(R.array.reply_choices)).build(); notificationBuilder.extend(new NotificationCompat.WearableExtender(). addAction(new NotificationCompat.Action.Builder(R.drawable. ic_voice_search,"Reply", navigationIntent).addRemoteInput(remoteInput). build()));
  18. None
  19. Extra Pages : - Create notifications and add them to

    wearableExtender.
  20. Packaging of the App for Publishing • You need to

    package wearable app inside handheld app • You should give dependency of wearable app inside mobile’s app build.gradle file • dependencies { • MyFirstWearApp project(':wearable') • }
  21. -Include all the permission declared in the wearable manifest file

    to mobile module manifest file. - Ensure common version number and package name for both modules.
  22. Do’s - Design for big gestures - Design it in

    a way, so that user should not take more than 5 seconds to use. Otherwise you should reconsider the design. - Do one thing at a time. - Keep the long running logic on your mobile side.
  23. Dont’s - Do not overload operation for wear apps -

    Do not demand unnecessary data from handheld devices - Stay careful about interactive and ambient mode
  24. Android Wear 2.0 preview - System UI - Standalone Apps

    - Real Time walking, bicycling and Running recognition.
  25. System UI: - Material design for wearable - Darker UI

    - Watch hardware button works like a back button - You can reply by voice, emojis and keyboard
  26. Standalone Apps : - Tethered + Untethered - Apps run

    on watch even when your phone is not with you - Doze - Handle notifications completely from wearable device. - Direct download from play store
  27. Real Time walking, bicycling and Running recognition.

  28. Here you can find more : DevBytes : https://www.youtube.com/watch?v=o5cne6vK- eo&index=9&list=PLWz5rJ2EKKc-kIrPiq098QH9dOle-fLef

    https://developer.android.com/training/wearables/apps/creating.html
  29. Q&A

  30. Thank you. @DevavrataSharma devavrata@techjini.com

  31. None