Power API

Power API is a library API and provides the ability to request the detailed information of the following:

Battery information

The following are the battery information and is obtained from the battery driver:

  • Nominal battery capacity - Maximum battery capacity and it decreases with time from usage and numbers of recharges.

  • Remaining battery capacity - Present battery capacity.

  • Remaining battery percentage

Battery voltage and current consumption

Power API simultaneously provides the following battery voltage and current consumption information:

  • Average battery voltage - the API returns the average battery voltage over a specified time interval.

  • Minimum battery voltage - minimum voltage on a battery that is required to drive the circuit.

  • Maximum battery voltage - maximum voltage that a battery can have.

  • Battery current consumption - average current consumed between specified start and end times.

Related concepts
Power API Tutorial