I need to get exact angle of my android device from each axis.
First I should say I searched through web and also stackoverflow and I saw pages like these:
How to measure the tilt of the phone in XY plane using accelerometer in Android
Get Android rotation angle in x-axis
But they were not helpful. I used some of them but they give wrong values.
If the axis in device will be like this:
I need to get these rotation angle:
I don't want to use any hardware sensor except accelerometer and I work with API 17. I think this is possible based on racing games, but I don't know how to do that.
I will appreciate if you help me. Thanks