Questions tagged [android-wear-data-api]

The Wearable Data Layer API, which is part of Google Play services, provides a communication channel for your handheld and wearable devices.

About

The API consists of a set of data objects that the system can send and synchronize over the wire and listeners that notify your apps of important events with the data layer.

Dependencies

  • Android 4.3 (API Level 18) or higher on the handheld device
  • Android 4.4W (API Level 20) or higher on the Android Wear device
  • Google Play services version 5.0 or higher
  • An Android Wear device or Wear AVD

Links

288 questions
1
vote
2 answers

Sync data with android wear

Mobile - Activity public class TestActivity extends Activity implements DataApi.DataListener, GoogleApiClient.ConnectionCallbacks, GoogleApiClient.OnConnectionFailedListener{ private GoogleApiClient mGoogleApiClient; Button syncBtn; static int…
Neha
  • 135
  • 1
  • 7
1
vote
1 answer

Using Shared Preferences to persist DataMap android wear

I had a question related to the FORM Watch Face. I see that SharedPreferences have been used to persist DataMap. Why was it necessary to persist the data when we can fetch the DataMap from the Wearable.DataApi anytime? The developer.android wearable…
ragdroid
  • 271
  • 3
  • 12
1
vote
1 answer

Android wearables: How to handle the event of a connected device?

From the smartwatch I'd like to intercept the event of the connection to a smartphone. This is automatically managed by Android and Android Wear so I need to get this event from my app running on the watch. I found out this on WearableAPI to be…
1
vote
1 answer

Data Stream from Wearable to Android Handheld

What is the best way to send a data stream from the wearable to the phone? I have a watch which generates a constant stream of data, which I want to send to the phone. None of the data packets should get lost. That means data needs to be chached as…
ChiefMiami
  • 63
  • 3
1
vote
1 answer

Send data and wait for the answers with the Wearable Data Layer API

I have a wearable device from which data is sent to a handheld device wrapped in a DataMap object. On the handheld device I implemented a listener service that extends WearableListenerService implemented in this way: public class ListenerService…
Dev
  • 7,027
  • 6
  • 37
  • 65
1
vote
1 answer

WearableListenerService - onPeerConnected never called

I created simple Phone<->Wear App. Wear app has one Activity with code: public class MainActivity extends Activity implements GoogleApiClient.ConnectionCallbacks { private TextView mTextView; @Override protected void onCreate(Bundle…
michal.luszczuk
  • 2,883
  • 1
  • 15
  • 22
1
vote
1 answer

Data Sync from wearable to handset

I want to create a wear app that I can start on my phone, and upon start queries my handset to do some network io, which then packages the result into a format that I can render back on the wearable device. I want to have the handset store some…
user1089599
  • 303
  • 6
  • 20
1
vote
2 answers

Transferring assets from watch to handheld

I'm trying to replicate this function https://developer.android.com/training/wearables/data-layer/assets.html. The transmitter part in watch is fine. In the onDataChanged function of WearableListenerService in handheld, an exception occurred every…
1
vote
1 answer

Not able to fetch data from Wear Data layer

I'm trying to sync a list from the handheld to the wearable. On the phone side, I have a listview and you can add items to it and on the wear side I am just displaying the same list. I'm adding items to /card/id path and adding the array size on…
1
vote
4 answers

Two WearableListenerService listening for messages from single wearable app

I'm having an issue where I want to have two diffrent WearableListenerServices listening for messages from a wearable app. Both extending WearableListenerService and configured thusly:
Simon
  • 13
  • 5
1
vote
2 answers

Android Wearable.DataApi: reliable data storage?

Background: I have an app which runs on an Android handheld (phone) but whose main purpose is to interact with an Android Wear watch. Correspondingly, the main source of data in the app is the wearable (not the handheld). I'm not currently using the…
Sterling
  • 6,365
  • 2
  • 32
  • 40
1
vote
1 answer

How to lauch the app in mobile while a button clicked in wear watch?

i am new in developing android wear applications. I would like to know how to do an action in mobile device by receiving a button click in android wear watch? For example a button in wear application to start activity in mobile device.
1
vote
1 answer

Transfer speed Android Wear DataApi?

What transfer speed can I expect when transferring data from phone to wearable using the Wearable DataApi? My idea is to transfer files to the wearable from the phone. It's loads of images so I zip them first and then transfer the zip file as an…
exkoria
  • 1,176
  • 2
  • 13
  • 27
1
vote
1 answer

Sending message to disconnected mobile from wearable

I'm trying to send an event or better a message to the mobile while the wearable is disconnected. Here is the code I'm using: Wearable.MessageApi.sendMessage( mGoogleApiClient, node, event, message).setResultCallback( new…
rekire
  • 47,260
  • 30
  • 167
  • 264
1
vote
1 answer

NotificationListenerService Wearable

I am trying to implement a way to detect the notifications that are sent to the android wearable devices. After googling around, I have found it is not possible to use notificationListenerService on the wearable. In current implementation, I have…