安卓:如何提高加速度计采样率? [英] Android: How to increase Accelerometer Sampling Rate?

查看:641
本文介绍了安卓:如何提高加速度计采样率?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前使用的Java API来获取在5HZ,低于我的要求加速度值。我想至少要达到50赫兹。有什么办法来提高加速度计的采样率是多少?

I am currently using Java API to get accelerometer values in 5Hz, which is below my requirements. I want to achieve at least 50Hz. Is there any way to increase the sampling rate of accelerometer?

问候

推荐答案

我觉得maximun采样率diferent Android手机之间diferent。我认为你能做的就是设置了的SensorManager尽可能快,因为它可以更新数据,一起来看看恒定的<一个href=\"http://developer.android.com/reference/android/hardware/SensorManager.html#SENSOR_DELAY_FASTEST\"相对=nofollow> SENSOR_DELAY_FASTEST从文档。

I think the maximun sampling rate is diferent between diferent android phones. What i think you can do is setup the sensormanager to update the data as fast as it can, take a look of the constant SENSOR_DELAY_FASTEST from the documentation.

问候。

这篇关于安卓:如何提高加速度计采样率?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆