自 2025 年 3 月 27 日起,我们建议您使用 android-latest-release
而非 aosp-main
构建 AOSP 并为其做出贡献。如需了解详情,请参阅 AOSP 的变更。
功耗
使用集合让一切井井有条
根据您的偏好保存内容并对其进行分类。
低功耗传感器
部分传感器类型被定义为低功耗传感器。低功耗传感器必须以低功耗运行,其处理在硬件中完成。这意味着它们不要求 SoC 处于运行状态。以下是部分低功耗传感器类型:
- 地磁旋转矢量传感器
- 大幅度动作传感器
- 计步器
- 步测器
- 倾斜检测器
在复合传感器类型汇总表中,这些传感器都带有低功耗 (
) 图标。
这些类型的传感器无法以高功耗实现,因为它们的主要优势就是低电耗。预计这些传感器会长时间启用,很可能是全天候启用。与其将低功耗传感器实现为高功耗传感器,还不如不要实现低功耗传感器,因为这会严重消耗电池电量。
复合低功耗传感器(如步测器)必须在硬件中进行处理。
有关具体功耗要求,请参阅 CDD,并在 CTS 中运行测试以验证这些功耗要求。
功耗测量过程
功耗按照电池电量测量。对于以毫瓦为单位的值,我们使用电池的标称电压,即在 4V 电压条件下的 1mA 电流必须计为 4mW。
当 SoC 处于休眠状态时,测量功耗;在 SoC 进入休眠状态几秒内,计算功耗平均值,因此需要考虑传感器芯片的周期性峰值。
对于单次唤醒传感器,在传感器未触发时测量功耗(因此不会唤醒 SoC)。同样,对于其他传感器,在将传感器数据存储在硬件 FIFO 中时测量功耗(因此不会唤醒 SoC)。
当没有传感器处于启用状态时,功耗通常以增量测量。当多个传感器处于启用状态时,功耗增量不得大于每个已激活传感器的功耗总和。如果加速度计消耗 0.5mA,而步测器消耗 0.5mA,同时启用这两种设备的功耗必须少于 0.5+0.5=1mA。
本页面上的内容和代码示例受内容许可部分所述许可的限制。Java 和 OpenJDK 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2025-07-27。
[[["易于理解","easyToUnderstand","thumb-up"],["解决了我的问题","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["没有我需要的信息","missingTheInformationINeed","thumb-down"],["太复杂/步骤太多","tooComplicatedTooManySteps","thumb-down"],["内容需要更新","outOfDate","thumb-down"],["翻译问题","translationIssue","thumb-down"],["示例/代码问题","samplesCodeIssue","thumb-down"],["其他","otherDown","thumb-down"]],["最后更新时间 (UTC):2025-07-27。"],[],[],null,["# Power consumption\n\nLow-power sensors\n-----------------\n\nSome sensor types are defined as being low power. Low-power sensors must\nfunction at low power, with their processing done in the hardware. This means\nthey should not require the SoC to be running. Here are some low-power sensor\ntypes:\n\n- Geomagnetic rotation vector\n- Significant motion\n- Step counter\n- Step detector\n- Tilt detector\n\nThey are accompanied by a low-power () icon in the [Composite sensor type\nsummary](/docs/core/interaction/sensors/sensor-types#composite_sensor_types) table.\n\nThese sensor types cannot be implemented at high power as their primary benefit\nis low battery use. These sensors are expected to be activated for very long\nperiods, possibly 24/7. It is better to not implement a low-power sensor at all\nrather than implement it as high power, as it would cause dramatic battery\ndrain.\n\nComposite low-power sensor types, such as the step detector, must have their\nprocessing conducted in the hardware.\n\nSee the CDD for specific power requirements, and expect tests in CTS to\nverify those power requirements.\n\nPower measurement process\n-------------------------\n\nThe power is measured at the battery. For values in milliWatts, we use the\nnominal voltage of the battery, meaning a 1mA current at 4V must be counted as\n4mW.\n\nThe power is measured when the SoC is asleep, and averaged over a few seconds\nof the SoC being asleep, so that periodic spikes in power from the sensor chips\nare taken into account.\n\nFor one-shot wake-up sensors, the power is measured while the sensor doesn't\ntrigger (so it doesn't wake the SoC up). Similarly, for other sensors, the\npower is measured while the sensor data is stored in the hardware FIFO, so the\nSoC is not woken up.\n\nThe power normally is measured as a delta with when no sensor is activated.\nWhen several sensors are activated, the delta in power must be no greater than\nthe sum of the power of each activated sensor. If an accelerometer consumes\n0.5mA and a step detector consumes 0.5mA, then activating both at the same time\nmust consume less than 0.5+0.5=1mA."]]