Skip to content
Simple GDK example acting as a compass. In addition to the visual display, you can tap the touchpad to have Glass speak your current orientation aloud.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
app Adding support for en_GB locale, contextual voice command and switchi… Sep 8, 2014
gradle/wrapper Adding support for en_GB locale, contextual voice command and switchi… Sep 8, 2014
.gitignore Redesign compass visuals, switched from deprecated TYPE_ORIENTATION s… Jul 26, 2013
LICENSE Initial commit Jul 22, 2013
README.md Updated for XE16. Apr 14, 2014
build.gradle
gradlew Adding support for en_GB locale, contextual voice command and switchi… Sep 8, 2014
gradlew.bat Adding support for en_GB locale, contextual voice command and switchi… Sep 8, 2014
settings.gradle

README.md

Compass

This sample inserts a live card to the left of the Glass clock that displays a compass. Tapping the live card presents a menu with two options:

  • Read aloud: read the compass's current heading using text-to-speech
  • Stop: remove the compass from the timeline

The compass also contains a small list of landmarks that will appear on the screen when the user is within 10 km of those locations. See the res/raw/landmarks.json file to add your own.

Getting started

Check out our documentation to learn how to get started on https://developers.google.com/glass/gdk/index

Running the sample on Glass

You can use your IDE to compile and install the sample or use adb on the command line:

$ adb install -r CompassSample.apk

To start the sample, say "ok glass, show a compass" from the Glass clock screen or use the touch menu.

You can’t perform that action at this time.