检测的Andr​​oid设备在电梯里 [英] Detect android device inside an elevator

查看:154
本文介绍了检测的Andr​​oid设备在电梯里的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想如果一个人采用了android传感器上升/下降的电梯检测。
但是我不知道它是可行的。
是疗法什么办法可以使用​​加速度计或类似的东西在Android设备是在电梯里检测?

I'm trying to detect if a person is going up/down in elevator using android sensors. But im not sure if it's feasible. Is ther any way you can detect when an android device is inside an elevator using accelerometer or something similar?

更新

我tryied使用pressure传感器,它似乎像pressure并没有改变在所有!

I've tryied to use the pressure sensor and it seems like the pressure doesnt change at all !

推荐答案

您可以用pressure传感器检测高度的变化它是一个封闭的空间在室内。

You can detect changes in height using the pressure sensor - however the pressure in the elevator may not actually change as expected due to factors like it being an enclosed space indoors.

您也可以使用加速度计来检测初始加速度和电梯的最终减速,但一切完全取决于手机在他们的手/袋/包的方向。

You could also use the accelerometer to detect the initial acceleration and final deceleration of the elevator but all that completely depends on the orientation of the phone in their hand/pocket/bag.

这将是一个非常困难的任务,并且将需要一个特定的环境中有效地工作(总是在相同的取向电话,改变在电梯pressure没有外部因素)。

It would be a very difficult task, and would require a particular environment to work effectively (phone always at the same orientation, no external factors changing the pressure in the elevator).

这篇关于检测的Andr​​oid设备在电梯里的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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