[英]What devices support Android Sensor Batching?
KitKat introduced sensor batching but I could not find a list of devices that support this. KitKat引入了传感器批处理,但我找不到支持此功能的设备列表。 In particular I am interested whether the 2013 HTC One supports it.
特别是我对2013 HTC One是否支持它感兴趣。
Is there a (community maintained?) resource that lists the supported devices? 是否有(社区维护?)资源列出支持的设备?
If sensor batching is not available on the HTC One, are there any good low-power gps tracking libraries? 如果HTC One上没有传感器批处理,那么有没有好的低功耗gps跟踪库? I would love to not have to write my own geofencing code (I assume this would be the most power-saving way to track the phone location)
我希望不必编写自己的地理围栏代码(我认为这将是追踪手机位置最省电的方式)
Thanks 谢谢
Using this code: 使用此代码:
SensorManager mgr = (SensorManager) getSystemService(SENSOR_SERVICE);
Sensor accelerometer = mgr.getDefaultSensor(Sensor.TYPE_ACCELEROMETER);
int fifoSize = accelerometer.getFifoReservedEventCount();
if (fifoSize > 0) {
//Device supports batched sensor updates
}
in an Activity that implemented a SensorEventListener. 在实现SensorEventListener的Activity中。 I found the following devices supported batched sensor updates:
我发现以下设备支持批量传感器更新:
and these did not: 而这些没有:
Sorry :(. I will update with more devices when I get my hands on them 抱歉:(。当我拿到手时,我会更新更多设备
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.