What makes accessing userAcceleration different from raw accelerator data (not the data itself)

I noticed after building an app around MotionManager's raw sensor data that there is DeviceMotion sensor data that removes bias in the raw data (gravity).


I figrued just switching out the MotionManager object with DeviceMotion and switching out the sensor data would just work but instead I'm getting memory access errors like mentioned here..


https://stackoverflow.com/questions/4281956/iphone-motion-exc-bad-access


I'm very new to iOS / Swift development so a bit confused why objects that seem to provide similar data would require completely different handling (that I'm not sure how to handle)

Replies

Got this working but it took twice number of lines just to access the equivalent data points.