计算机器人传感器的功耗 [英] Calculate Android sensor power consumption

查看:158
本文介绍了计算机器人传感器的功耗的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

<一个href="http://developer.android.com/reference/android/hardware/Sensor.html#getPower%28%29">getPower()返回所使用的传感器毫安的能力,同时在使用中:

getPower() returns the power in mA used by a sensor while in use:

现在,我需要计算多少电池所使用的传感器的登记

Now, I need to calculate how much battery is used by the registration of the sensor.

难道他珍视getPower()返回表示毫安(每小时毫安),或者其他什么东西? 如果是的话,有没有办法让电池毫安,以计算所使用的传感器电池的%?

Does he value returned by getPower() indicate the mAH (mA per HOUR) or something else? If yes, is there a way to get the battery mAH in order to calculate the % of battery used by the sensor?

推荐答案

东西很相关的已在谷歌集团不久前讨论。你可以找到href="https://groups.google.com/group/android-developers/browse_thread/thread/6069056189b02d29"这里仅供参考rel="nofollow">全螺纹的

Something quite related has been discussed in Google groups not too long ago. You can find the full thread here for reference.

这是在该线程的最后答复,这应该回答你的问题少量摘录或多或少的:

A small excerpt from the last reply in that thread, which should answer your question more or less:

(...)电池容量总是以毫安计给出。 (...) 什么   事项是多长的电池可以提供给定的电流在其   额定电压。 3800MAH意味着它可以提供3800毫安1小时。   认识到这一点很有道理,现在的API是提供当前   漏极作为功率消耗的量度。现在,您可以计算出有多少   实现它将会对电池的寿命作为时间的函数。

(...) the battery capacity is always given in terms of mAH. (...) What matters is how long a battery can supply a given current at its rated voltage. 3800mAH means that it can supply 3800mA for 1 hour. Knowing this it makes sense now that the API is providing the current drain as a metric of power consumption. You can now calculate how much effect it will have on the battery life as a function of time.

这篇关于计算机器人传感器的功耗的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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