Access Android Wear Fit Data

故事扮演 提交于 2019-12-03 06:18:09

I guess the only option right now is for you to create your own heart rate and step counter apps that share historical data through content providers. I've written a quick tutorial on how to get data from heart rate sensor here.

As far as I've been able to tell, there's no public api that accesses the fitness data from the watch. I'm fairly confident that will become available when the Fitness SDK opens up, but that may be a while.

Until then, the only way I believe you can access that data is by reading the fitness app's private sqlite database. Unfortunately, you will need root to access it. It's located at:

/data/data/com.google.android.apps.fitness/databases/pedometer.db

It contains two tables worth looking at: heartrate and stepcount. Both are very simple. (Note: this is taken from a G Watch, and both tables exist, but the heartrate data is empty, as you would expect.)

I'm going to keep poking around in the apks to figure out of there's a queryable service, but I haven't seen one yet.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!