title: How to use DataItem of Android Wear
body: <p>I want to sync preference between handhelds and wearables. I implement <a href="http://developer.android.com/training/wearables/data-layer/data-items.html" rel="noreferrer">sample code</a> on handheld app.</p>
  <pre><code>PutDataMapRequest dataMap = PutDataMapRequest.create(&quot;/count&quot;);
  dataMap.getDataMap().putInt(COUNT_KEY, count++);
  PutDataRequest request = dataMap.asPutDataRequest();
  PendingResult&lt;DataApi.DataItemResult&gt; pendingResult = Wearable.DataApi
      .putDataItem(mGoogleApiClient, request);
  System.out.println(dataMap.getDataMap().getInt(&quot;COUNT_KEY&quot;));//print 3
  </code></pre>
  <p>And then implement below code on wearable app. But saved count can't be retrieved.</p>
  <pre><code> PutDataMapRequest dataMap = PutDataMapRequest.create(&quot;/count&quot;);
   int count = dataMap.getDataMap().getInt(&quot;COUNT_KEY&quot;);
   System.out.println(count);//print 0
  </code></pre>
  <p>I tried in actual android handheld device and emulator of Android wear. I confirmed they are connected by using demo cards of Android Wear app.</p>
  <p>What I need more or do I misunderstand something?</p>