I am using Core Motion to get the attitude of the device.
My problem is that using CMAttitudeReferenceFrameXTrueNorthZVertical
makes
my Motion Manager breaking up. I use Core Location and start location updates before
starting device motion updates but my CMDeviceMotion
object is always nil
.
Because I thought I made a mistake I downloaded the pARk sample code (Link to sample code) from Apple, where
they also use CMAttitudeReferenceFrameXTrueNorthZVertical
and CoreLocation
and this is also not working.
I have an iPhone4S which shouldn't be the problem, because it's the newest hardware...
If I use CMAttitudeReferenceFrameXMagneticNorthZVertical
instead, everything works properly.
Any suggestions?
Problem solved.
This was because of deactivated compass calibration in the iOS 5 settings. I think this means the location mode may not be used for getting the true north.
Because of that also Wikitude was not working properly...