Using orientation information to get down direction
问题 I am working on an app that involves drawing a line on my android screen based on its orientation and could use some help or pointers. The line is drawn in the following way: If the phone is held flat then then the line shrinks and becomes a dot and as the phone is tilted and orientatated the line becomes bigger - ie the phone stood up and the line points down and is max magnitude of 9.8 and held flat it is a small dot. Crucialy no matter what angle the phone is held at the arrow allways