Does HealthKit step count show on xcode simulator
Asked Answered
A

2

10

I am building an app and retrieving a users step count from HealthKit

There is no error, and I was curious to see if when you run code on xcode using the simulator the step count will always be 0 by default as locations are defaulted?

Anciently answered 28/2, 2018 at 13:15 Comment(0)
B
-6

I think no.. Apple Healthkit uses iPhone's hardware and some specific services to count the steps. In Simulator it's not possible.

Bonne answered 28/2, 2018 at 13:29 Comment(0)
S
38

That's actually possible. Follow the below step

  1. Go to simulator home and open 'Health' App. after that
  2. Tap on Health Data from the bottom menu.
  3. Tap on Activity Box
  4. Scroll down and find steps and tap on it.
  5. To add custom steps tap on '+' icon on the top right corner.

You can now add dummy steps data for Apple Health Kit. Cheers!

Subterfuge answered 21/11, 2018 at 3:32 Comment(1)
great little tip for getting this working on a simulatorMoluccas
B
-6

I think no.. Apple Healthkit uses iPhone's hardware and some specific services to count the steps. In Simulator it's not possible.

Bonne answered 28/2, 2018 at 13:29 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.