Aggregated CMPedometerData (iPhone + Watch total count)

后端 未结 1 1170
不思量自难忘°
不思量自难忘° 2020-12-22 08:47

My app collects CMPedometerData both on the iPhone and the Watch.

iPhone\'s steps number (both in real time and historical data) are significantly l

相关标签:
1条回答
  • 2020-12-22 09:04

    HealthKit uses HKStatisticsQuery and HKStatisticsCollectionQuery to compute the aggregated step count from several devices. These methods automatically detect overlaps in the measurements and get rid of the duplicate entries.

    You can find some sample in in the official documentation of HKStatisticsQuery.

    0 讨论(0)
提交回复
热议问题