Make Your Existing App Android Wear Compatible presented at jPrime conference which is held at Sofia, Bulgaria on 27th May, droidcon conference which is held at Thessaloniki, Greece on 11th September 2015.
* Introduction * Thanks jPrime and JUG community * will talk about Android Wear
* google developer groups ankara
some of the android wear devices samsung, intel, motorola, lg round and square ones
activity tracking(running, exercising) apps monitoring your heart rate messaging apps phones’ batteries last longer with android wear don’t need to check phone on every little sound!
now, how to make our existing apps, wearable compatible the easiest one, notifications
the same notification will be seen in the Android Wear device as well. The only thing to do is using NotificationCompat class to create notifications. in the picture, you can see an example screenshot of hangouts app, both on handset and wear.
So how to make this? first of all create pending intents that will be triggered when actions are called on notifications. These are like usual notifications on handset. in this example there are two pending intents, first one opens the MainActivity, the second one opens the dialler application.
* Then we create an action with NotificationCompat class. It is for an extra button for the notification.
Then again we use NotificationCompat class to build a notification. The trick of the code is, we add the “action” that we created on previous slide, just to shown on the wearable device, not on the handset. It is done by NotificationCompat.WearableExtender() If you add actions by using this, these actions will only shown on wears.
This is how it will look like, almost. The notification will be shown on the handset, either. But without the “Reply” action.
The comparison of the notifications on handset and wear. As you see, there are less information, less detail on the wear. So we should care about this. Simple is the best, especially on the Wear! :)
Some example screens of wear notifications. You can also get input from wear. Especially with voice, but if it is not possible you can get input with short commands. Like yes,no,maybe. They are useful for the environment that is not suitable to get voice input.
The other thing to make your Android app, Android Wear compatible is the “REAL WEAR APPS” They are almost like usual Android apps, but with less resource. I will not talk about the Android Wear apps in detail. But let’s look it a little.
These are some of the Android Wear apps on the Play Store There are lots of Wear apps on the Play Store and their amount is increasing day by day.
A calculator app for wear, a screen light app, and an app that has a great ux/ui for wearables — a weather app.
YES, there is no limit with your imagination. Just one limit! Resource :) You must care for battery, ram, cpu of the Wearable device.
now let’s set up the development environment. we just need the android studio and the latest sdk’s of android and android wear. And an Android device also :)
There is one important thing to take care. Every time that you connect your phone to the computer via USB, you should make the port forwarding again. Otherwise, the Wear emulator and the phone will not be paired.
Yes we are ready now. Let’s make a demo
Thank you for listening me. I am very happy to be here. Thanks again to jPrime team! You can contact me via twitter and e-mail. Now, if we have enough time, i can try to answer your questions.
Make Your Existing App Android Wear Compatible
Yep, it is wearable now!
Who am I?
Co-Founder / CEO at
Co-Organizer at GDG Ankara
Create an Android Wear emulator
Install Android Wear app to your phone
Connect your phone to your computer
Open up Terminal and make the port forwarding
via this command:
adb -d forward tcp:5601 tcp:5601
Run the Android Wear Emulator and select “pair
with emulator” option from Android Wear app
It is DONE!
You can start to develop
for Android Wear, now!
A little DEMO! :)