Core Motion mode CMAttitudeReferenceFrameXTrueNorthZVertical not working on specific devices
When using Core Motion with CMAttitudeReferenceFrameXTrueNorthZVertical some devices consistently return a CMErrorTrueNorthNotAvailable (error code 102) in the in the CMDeviceMotionHandler block. It can be reproduced in 100% of the cases on affected devices. A reset of the iOS settings solves the problem.
Steps to Reproduce:
Run the pARk sample app on an affected device.
The labels should move on the screen depending on the orientation of the device.
The labels stay in the center of the screen and never move. (Screenshot: http://d.pr/i/dyjI)
This happens at least since iOS 6.0. It happens only on a tiny fraction of devices but on those devices it is 100% reproducible. We've reports from only a handful of devices out of a user base of many thousands (the Augmented Reality mode in Where To? http://itunes.apple.com/app/id314785156?mt=8).
To actually obtain the NSError object the pARk app has to be modified to use
-startDeviceMotionUpdatesUsingReferenceFrame:toQueue:withHandler: instead of
This is the NSError received:
Error Domain=CMErrorDomain Code=102 "The operation couldn’t be completed. (CMErrorDomain error 102.)"
After receiving the error callback, no further callbacks are received. cmMotionManager.deviceMotion is always nil.
The error (CMErrorTrueNorthNotAvailable) hints at a Core Location problem. Therefore we had the customer test Core Location on the affected device and verified it's working correctly: CMLocationManager updates are received and MKMapView displays the blue userLocation dot.
We tried a little modification of the pARk app: We replaced CMAttitudeReferenceFrameXTrueNorthZVertical by CMAttitudeReferenceFrameXMagneticNorthZVertical and it worked fine. So only the CMAttitudeReferenceFrameXTrueNorthZVertical mode is affected.
Then we had the customer reset "All Settings" using General => Reset => All Settings and the problem disappeared. Apparently there is some corrupt system setting that triggers this bug.
Reports posted here will not necessarily be seen by Apple.
All problems should be submitted at bugreport.apple.com before they are posted here.
Please only post information for Radars that you have filed yourself, and please do
not include Apple confidential information in your posts. Thank you!