我的传感器管理器有问题,logcat 中有错误。当我用这一行注册监听器时:
sensorMgr.registerListener(this, sensorMgr.getDefaultSensor(Sensor.TYPE_ACCELEROMETER), SensorManager.SENSOR_DELAY_NORMAL);
我在 logcat 中收到这些行,但有三个错误。
06-07 20:52:42.419: D/SensorManager(9215): ====>>>>>Num Sensor: 1
06-07 20:52:42.419: D/SensorManager(9215): ====>>>>>Num Sensor: 2
06-07 20:52:42.419: D/SensorManager(9215): ====>>>>>Num Sensor: 3
06-07 20:52:42.419: D/SensorManager(9215): ====>>>>>Num Sensor: 4
06-07 20:52:42.419: D/SensorManager(9215): ====>>>>>Num Sensor: 5
06-07 20:52:42.419: D/SensorManager(9215): ====>>>>>Num Sensor: 6
06-07 20:52:42.419: D/SensorManager(9215): ====>>>>>Num Sensor: 0
06-07 20:52:42.419: E/SensorManager(9215): registerListener :: handle = 0 name= BMA220 delay= 200000 Listener= fr.rocknscrum.liseronmobile.MainActivity@40520980
06-07 20:52:42.419: E/SensorManager(9215): =======>>>Sensor Thread RUNNING <<<========
06-07 20:52:42.429: E/SensorManager(9215): reg :: handle = 0
它工作得很好,没有问题,但我怎样才能避免这些错误?
PS:我不使用已弃用的版本。