1
2page.tags="WatchFace"
3sample.group=Wearable
4@jd:body
5
6<p>
7
8This sample demonstrates how to create watch faces for android wear and includes a phone app
9and a wearable app. The wearable app has a variety of watch faces including analog, digital,
10opengl, calendar, steps, interactive, etc. It also includes a watch-side configuration example.
11The phone app includes a phone-side configuration example.
12
13Because watch face apps do not have a default Activity in their project, you will need to set your
14Configurations to "Do not launch Activity" for both the Wear and Application modules. If you are
15unsure how to do this, please review the "Run Starter project" section in the
16[Google Watch Face Code Lab][1].
17
18For the Fit Distance related watch face, authentication IS a requirement to request distance from
19Google Fit on Wear. Otherwise, distance will always come back as zero (or stay at whatever the
20distance was prior to you de-authorizing the watch face).
21
22To authenticate and communicate with Google Fit, you must create a project in the Google Developers
23Console, activate the Fitness API, create an OAuth 2.0 client ID, and register the public
24certificate from your signed APK. More details can be found [here][2].
25
26If the user has not installed or setup the Google Fit app on their phone and their Wear device has
27not configured the Google Fit Wear App, then you may get zero steps until one of the two is setup.
28Please note, many Wear devices configure the Google Fit Wear App beforehand.
29
30[1]: https://codelabs.developers.google.com/codelabs/watchface/index.html
31[2]: https://developers.google.com/fit/android/get-started#step_3_enable_the_fitness_api
32
33        </p>
34