iPhone中的加速度计范围 [英] accelerometer range in iPhone
本文介绍了iPhone中的加速度计范围的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我已经在我的应用程序中实现了以下方法.
i have implemented following method in my application.
- (void)accelerometer:(UIAccelerometer *)acel didAccelerate:(UIAcceleration *)aceler {
if (fabsf(aceler.x) > 1.5 || fabsf(aceler.y) > 1.5 || fabsf(aceler.z) > 1.5 || fabsf(aceler.x) < -1.5 || fabsf(aceler.y) < -1.5 || fabsf(aceler.z) < -1.5 )
{
self.navigationItem.rightBarButtonItem=nil;
[self showImage:nil];
}
}
=>我很想知道"aceler.x的范围".
=> I am eager to know " The range of aceler.x ".
即aceler.x/y/z的最大值是多少
i.e. what would be the maximum value of aceler.x / y / z
最低收费是多少? (我认为应该为零)
Same way the minimum ? ( I think, it should be zero )
预先感谢您的帮助.
推荐答案
快速搜索显示iPhone使用的是页面中,我遇到了,提到输出固定在2.37G,因此看来它们使用2G模式或仅支持2G的LIS302.
A quick search shows that the iPhone uses a LIS302 accelerometer. The datasheet I linked shows +-2G or +-8G. There is also a version of the LIS302 that only does +-2G. From another page I came across, mentions the output pegging out at 2.37G, so it appears they use the 2G mode or the LIS302 that only supports 2G.
这篇关于iPhone中的加速度计范围的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文