0

When you normaly build an Compass app u use something like this:

@Override
public void onSensorChanged(SensorEvent event) {
        int myAzimuth = Math.round(event.values[0]); //Angle

}

But I want to read the Data on my own something like: mSensorManager.getCompassAngle()

Is there a way without listener ?

thanks!

Cracker0dks
  • 2,154
  • 1
  • 20
  • 36

1 Answers1

2

No, sorry -- SensorManager only works using a listener.

CommonsWare
  • 910,778
  • 176
  • 2,215
  • 2,253