How to get power_profile.xml files from Android phone

Source: Internet
Author: User

Recently in the test of energy consumption, read the paper for one months, finally found some new ideas, but a problem arose, so that

The work cannot go on any longer.

On Android phones, the energy consumption values for each part of the phone (CPU, LED, GPS, 3g, and so on) are Power_profile.xml

File, and the system is set up--in battery usage, the usage of the statistics is also based on the value of Power_profile.xml as the base parameter

the. How does Android phone get power_profile.xml files? Next we'll cover the problem in more detail:

Google's official website for power_profile.xml file Description: http://source.android.com/devices/tech/power.html

Step Illinois 1: Enter the Android phone system root directory, locate the systems file and open the file, locate the framework file and open, locate the framework-res.apk file (/system/framework/ FRAMEWORK-RES.APK).

Step Illinois 2: Use the Apktool tool to decompile the framework-res.apk.

1. Download Apktool. Http://code.google.com/p/android-apktool/downloads/list


2. Unzip the download, file directory structure.


3. Command line execution Apktool d E:\power_profile\framework-res.apk e:\power_profile\framework-res


Step Illinois 3: The post-compilation file directory is as follows,power_profile----framework-res-----RES----XML----power_profile.xml

in my phone. the power_profile.xml file is shown below (Xiaomi 2s):

<?xml version= "1.0" encoding= "Utf-8"?>
<device name= "Android" >
<item name= "None" >0</item>
<item name= "Screen.on" >100</item>
<item name= "Bluetooth.active" >142</item>
<item name= "Bluetooth.on" >0.3</item>
<item name= "bluetooth.at" >35690</item>
<item name= "Screen.full" >160</item>
<item name= "Wifi.on" >4</item>
<item name= "Wifi.active" >120</item>
<item name= "Wifi.scan" >220</item>
<item name= "Dsp.audio" >88</item>
<item name= "Dsp.video" >88</item>
<item name= "Radio.active" >300</item>
<item name= "Gps.on" >170</item>
<item name= "Battery.capacity" >1390</item>
<item name= "Radio.scanning" >70</item>
<array name= "Radio.on" >
<value>3</value>
<value>3</value>
</array>
<array name= "Cpu.speeds" >
<value>192000</value>
<value>384000</value>
<value>432000</value>
<value>486000</value>
<value>540000</value>
<value>594000</value>
<value>648000</value>
<value>702000</value>
<value>756000</value>
<value>810000</value>
<value>864000</value>
<value>918000</value>
<value>972000</value>
<value>1026000</value>
<value>1080000</value>
<value>1134000</value>
<value>1188000</value>
</array>
<item name= "Cpu.idle" >2.8</item>
<array name= "Cpu.active" >
<value>66.6</value>
<value>84</value>
<value>90.8</value>
<value>96</value>
<value>105</value>
<value>111.5</value>
<value>117.3</value>
<value>123.6</value>
<value>134.5</value>
<value>141.8</value>
<value>148.5</value>
<value>168.4</value>
<value>168.4</value>
<value>168.4</value>
<value>168.4</value>
<value>168.4</value>
<value>168.4</value>
</array>
</device>

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.