Discussion of methods for measuring and testing power consumption in arm devices

Registered by Steve Conklin on 2012-10-11

A discussion of best practices for measuring and reporting power consumption on low power devices. This will include software tools, lab testing environments, and tools for troubleshooting problems.

Blueprint information

Leann Ogasawara
Needs approval
Series goal:
Accepted for raring
Good progress
Milestone target:
milestone icon ubuntu-13.04-feature-freeze
Started by
Andy Whitcroft on 2013-01-04

Related branches



The Need:

Methods are needed for measuring, tracking, and investigating power consumption on low power devices. There is a need for this in two environments. The first is in the hands of the users of the systems, and the second is in an automated lab environment, suitable for automated regression testing.

Potential Resources:

https://bugs.launchpad.net/ubuntu-power-consumption (bugs found in previous power management exercise)

http://www.youtube.com/watch?v=aDStdtopy_g ARM Energy Probe

Potential Software Tools:

cking's PPA tools (powerstat, eventstat)

PowerTutor (an android app, would need porting)
PowerTutor does not Support the Nexus, and faults when run.

Automated Testing Tools:

The kernel team has already implemented a test system which directly monitors power consumption during execution of various tasks. This uses a precision meter and requires physical connection to the device. For battery powered devices, it is generally done by removing the battery so that battery charging current does not impact measurements. These tests are useful for automated testing of software releases, to compare power consumption across releases and detect regressions.

This should run much like the boot speed testing.

Power consumption will be tested on the latest daily image and report if the same test suite draws less or the same power as the day before (GREEN), or draws more (RED). QA will then contact the kernel team and they can make the determination if the RED test was due to normal variance or a bug needs to be filed and worked.

Tools for community participation:

Any of the tools listed above under 'Potential Software Tools' could be used by members of the community, but we have no framework for gathering, comparing, and analyzing the results. The android PowerTuror application does include some ability to report results, and is available under GPLv3. A determination would need to be made whether the application can be used with Ubuntu. Ubuntu uses the same kernel API as the application, but it looks like it has device interfaces to devices found on android devices, and equivalent functionality would be required for Ubuntu. The PowerTutor application does not run on the Nexus 7, so may be unstuiable in any case.


What would be the pros + cons of expanding this session to include non-ARM devices? -- mpt

See https://blueprints.launchpad.net/ubuntu/+spec/client-1303-power-consumption-testing for the continuation of this blueprint since it has more documentation about recent discussion on this.


Work Items

Work items for ubuntu-13.04-month-2:
[leannogasawara] Schedule kick off call with Kernel & QA teams: DONE
[mprasodjo] get data from ARM power blueprint/slides/notes into Nexus7 wiki: DONE
[colin-king] analyse the results from the battery (it may be that even thought the actual numbers are not accurate, if they are consistently repeatable, that may be enough to detect regressions) (see http://smackerelofopinion.blogspot.co.uk/2012/11/non-linear-characteristics-in-draining.html): DONE
[sconklin] find datasheets on this device (maybe not possible) [it wasn't possible, no response from vendors]: DONE
[sconklin] investigate ARM energy probe: DONE
[sforshee] invesigate power tutor, see what APIs it uses and see if it's portable onto Nexus7 (please send notes to mfisch when done): DONE

Work items for ubuntu-13.04-month-3:
[leannogasawara] Discuss the value of running Phronix tests in conjunction to ensure we don't regress (note I'm not convinced however it was a concern of rickspencer3): POSTPONED

Work items for ubuntu-13.04-month-4:
[sconklin] further investigate the user-space component that is doing some of the power control: DONE

Work items for ubuntu-13.04-beta-1:
[pgraner] get hardware wired up in the lab to support testing against the daily images: DONE

Dependency tree

* Blueprints in grey have been implemented.