I looked through the SensorManager and am still not sure how to determine if the phone is looking at the real north (or at any other direction for that matter).
If you're just looking for a sample, the publishers of Professional Android 2 Application Development have all the sample code available for download , and there is a compass app in chapter 14.
Source: https://habr.com/ru/post/1309392/More articles:How to invoke bean session from jsp - ejbWhen knowledge of "multithreading" is indicated in the description of work in C ++, what is this expectation? - c ++RSA Key Length and Export Restrictions - cryptographyAre there any special key events in Windows that I cannot handle? - c #How to read the value of the parent XML node tag in android - androidHow to format Excel worksheet cells using PHP - phpCustom sorting logic for groups using CollectionViewSource - wpfCapturing debug output in C # - debuggingAny foundation for administering the open source Android app? - androidIf the method does not use the fields of the object, is it thread safe? - javaAll Articles