I need to use the functionality of an accelerometer in my iPhone game. I just have to move an image by tilting the device. However most videos on YouTube just show the tilt feature that is somehow inverted and forget to include the calibration.
I want the user to calibrate their device to whatever position they're in. Does anyone know how I should get started on this?
I made an app like this once. I'll post it here, but it's for iOS 4...
To calibrate:
And...
.h file:
Move code:
Should work most of the time.