Skip to main content

Energy Monitoring (Beta)

info

Please note that this tool is classified as a Legacy tool. We recommend transitioning to our updated solutions to maintain optimal performance and security in your workflows. For more information on this matter, please reach out to technical support .

Parameters

  • PackageName: Application bundle ID followed by ':battery'.

Usage

Run startMonitor("ApplicationID:battery") to start energy monitoring of an installed application. Battery consumption is estimated based on the following components' usage:

  • On iOS :
  1. CPU

  2. location (GPS)

  3. GPU

  4. Networking

  • On Android:
  1. cpu_power_use (for energy consummed by CPU's operations related to the application).

  2. wifi_power_use (for WiFi).

  3. gpu*_power_use* (for GPU - screen consumption).

  4. rest_power_use (which groups usage by sensors, bluetooth, cellular, etc).

  5. total_usage (the sum of cpu_power_use, wifi_power_use , gpu_power_use, and rest_power_use).

  6. screen_power_use (for power consumed by the screen while the application was running in the foreground).

      The data is presented in unit mAh by default, but it can be also presented in percents (relatively to the full battery capacity). Command setproperty("battery.report.percentage", "true") switches the presentation unit to percents. The command is effective on its test only and has no effect on other tests.

      If a device does not provide details about battery drain caused by a particular component, N/A is reported as its value.

Supported only for Android versions 5.0+.

Every second a sample containing values for the aforementioned components is taken. The values describe the battery consumption during the time period since the previous sample, i.e., approximately a second. The collected data can be retrieved and exported in CSV format with command getMonitorsData.

On iOS devices, Energy monitoring is supported with some limitations:

  • Energy monitoring is only supported on local devices, i.e., not cloud devices.

  • Monitoring must be started after the application was launched.

  • If an application is closed, energy monitoring must be started again by executing startMonitor command.