Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Hands-on with Android Wear
Search
Breandan Considine
July 31, 2015
Programming
0
69
Hands-on with Android Wear
A beginners guide to getting up and running with Android Wear.
Breandan Considine
July 31, 2015
Tweet
Share
More Decks by Breandan Considine
See All by Breandan Considine
Intrinsic social motivation via causal influence in multi-agent RL
breandan
0
120
Deep, Skinny Neural Networks are not Universal Approximators
breandan
0
120
PRM-RL: Long-range Robotic Navigation Tasks by Combining Reinforcement Learning and Sampling-based Planning
breandan
0
150
DeepTest: Automated Testing of Deep-Neural-Network-driven Autonomous Cars
breandan
0
110
Idiolect: A Reconfigurable Voice Coding Assisant
breandan
0
220
Interactive Programming with Automated Reasoning
breandan
0
79
Learning Structural Edits via Incremental Tree Transformations
breandan
0
55
Thinking Like Transformers
breandan
0
89
Discriminative Embeddings of Latent Variable Models for Structured Data
breandan
0
60
Other Decks in Programming
See All in Programming
スキーマ駆動で、Zod OpenAPI Honoによる、API開発するために、Hono Takibiというライブラリを作っている
nakita628
0
330
AI時代に必須!状況言語化スキル / ai-context-verbalization
minodriven
2
300
ノーコードからの脱出 -地獄のデスロード- / Escape from Base44
keisuke69
0
330
3年ぶりにコードを書いた元CTOが Claude Codeと30分でMVPを作った話
maikokojima
0
730
開発組織の戦略的な役割と 設計スキル向上の効果
masuda220
PRO
10
2k
AsyncSequenceとAsyncStreamのプロポーザルを全部読む!!
s_shimotori
1
220
Webサーバーサイド言語としてのRustについて
kouyuume
1
5k
Making Angular Apps Smarter with Generative AI: Local and Offline-capable
christianliebel
PRO
0
100
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
480
AkarengaLT vol.38
hashimoto_kei
1
130
퇴근 후 1억이 거래되는 서비스 만들기 | 내가 AI를 사용하는 방법
maryang
2
330
Temporal Knowledge Graphで作る! 時間変化するナレッジを扱うAI Agentの世界
po3rin
5
1.2k
Featured
See All Featured
Code Reviewing Like a Champion
maltzj
526
40k
It's Worth the Effort
3n
187
28k
Building Flexible Design Systems
yeseniaperezcruz
329
39k
Done Done
chrislema
186
16k
Making Projects Easy
brettharned
120
6.4k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
31
2.7k
Bash Introduction
62gerente
615
210k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
34
2.5k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
37
2.6k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
10
640
XXLCSS - How to scale CSS and keep your sanity
sugarenia
249
1.3M
How to Ace a Technical Interview
jacobian
280
24k
Transcript
Hands-on with Breandan Considine JetBrains, Inc. AnDevCon Boston ‘15
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
Wearable Data Layer (Play Services) • Communication channel between handheld
and wearables • Google Play Services behind the scenes • Provides three API for communication • Data Layer API • Node Layer API • Message Layer API
Android Wear Communication Mobile App Google Play Services Wear App
Data Layer Node Layer Message
Wearable Data Layer API (Play Services) • All wearable communication
starts with the GoogleApiClient apiClient = new GoogleApiClient.Builder(this) .addConnectionCallbacks(this) .addOnConnectionFailedListener(this) .addApi(Wearable.API) .build();
Wearable Data Layer API @Override protected void onStart() { super.onStart();
apiClient.connect(); } @Override protected void onStop() { apiClient.disconnect(); super.onStop(); }
@Override public void onConnected(Bundle bundle) { Wearable.DataApi.addListener(apiClient, this); Wearable.MessageApi.addListener(apiClient, this);
Wearable.NodeApi.addListener(apiClient, this); } @Override protected void onPause() { super.onPause(); Wearable.DataApi.removeListener(apiClient, this); … } Listeners and Callbacks
// Sender Wearable.MessageApi.sendMessage(apiClient, transcriptionNodeId, PATH, byteArray); // Listener public void
onMessageReceived(MessageEvent me) { if (me.getPath().equals(PATH)){ … } } Message API • One-way communication channel between local and remote node
PendingResult<NodeApi.GetConnectedNodesResult> nodes = Wearable.NodeApi.getConnectedNodes(mGoogleApiClient); @Override public void onPeerConnected(Node node) {…}
@Override public void onPeerDisconnected(Node node) {…} Node API
PendingResult<CapabilityApi.GetCapabilityResult> capability = Wearable.CapabilityApi.getCapability( mGoogleApiClient, VOICE_TRANSCRIPTION_CAPABILITY_NAME, CapabilityApi.FILTER_REACHABLE); @Override public void
onCapabilityChanged(CapabilityInfo info) {…} <?xml version="1.0" encoding="utf-8"?> <resources> <string-array name="android_wear_capabilities"> <item>voice_transcription</item> </string-array> </resources> Capability API
Voice Actions • Like handheld, launching a wear app defaults
to android:label <activity android:name=".WearActivity" android:label="WearActivity"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> … </activity>
Special Thanks