accelerometer

Which is better :
* using a timer / callback and Sensor.getInfo() has :accel
or
*Sensor.registerSensorDataListener
to access accelerometer data ?
  • Sensor.registerSensorDataListener has more options for the accel data, you can select the frequency (1Hz-25Hz) and period (1s-4s), and also has other data points calculated like pitch roll, power etc.You do not have to use the timer hence saving some resources.