Search code examples
iphonecore-motion

Motion & Fitness on iPhone 5/5C


From what I know iPhone 5/5C do not have the motion processor like 5S and newer phones have, but when I request the motion permission the default alert with Allow and Don't allow still appears, even if I check before if the motion is available for device with MotionManager.isDeviceMotionAvailable. I would expect the alert not to appear for 5 and 5C.

What am I doing wrong here? Does 5 and 5C actually support motion?


Solution

  • As @the4kman said the device motion is available through accelerometer and a gyroscope.

    But what I actually meant and needed in this case is the user's activity, which is available through the M7 processor that is installed on 5S and newer and to check if that is available on a device I did CMMotionActivityManager.isActivityAvailable()