diff options
author | Amith Yamasani <yamasani@google.com> | 2009-07-13 16:02:45 -0700 |
---|---|---|
committer | Amith Yamasani <yamasani@google.com> | 2009-07-20 12:38:55 -0700 |
commit | 3f7e35c2c7d3d7f08f50c1d93cd16b1f49354ccc (patch) | |
tree | b4ce5865a36fbd440e84658cf053dfa900554910 /core/java/android/os/BatteryStats.java | |
parent | 5f6133a100d4477dfcea919e81ff301f9352cd32 (diff) | |
download | frameworks_base-3f7e35c2c7d3d7f08f50c1d93cd16b1f49354ccc.zip frameworks_base-3f7e35c2c7d3d7f08f50c1d93cd16b1f49354ccc.tar.gz frameworks_base-3f7e35c2c7d3d7f08f50c1d93cd16b1f49354ccc.tar.bz2 |
Bluetooth at command tracking.
Diffstat (limited to 'core/java/android/os/BatteryStats.java')
-rw-r--r-- | core/java/android/os/BatteryStats.java | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/core/java/android/os/BatteryStats.java b/core/java/android/os/BatteryStats.java index 528def5..e203fd5 100644 --- a/core/java/android/os/BatteryStats.java +++ b/core/java/android/os/BatteryStats.java @@ -508,6 +508,19 @@ public abstract class BatteryStats implements Parcelable { public abstract long getBatteryUptime(long curTime); /** + * @deprecated use getRadioDataUptime + */ + public long getRadioDataUptimeMs() { + return getRadioDataUptime() / 1000; + } + + /** + * Returns the time that the radio was on for data transfers. + * @return the uptime in microseconds while unplugged + */ + public abstract long getRadioDataUptime(); + + /** * Returns the current battery realtime in microseconds. * * @param curTime the amount of elapsed realtime in microseconds. @@ -1128,7 +1141,14 @@ public abstract class BatteryStats implements Parcelable { } if (!didOne) sb.append("No activity"); pw.println(sb.toString()); - + + sb.setLength(0); + sb.append(prefix); + sb.append(" Radio data uptime when unplugged: "); + sb.append(getRadioDataUptime() / 1000); + sb.append(" ms"); + pw.println(sb.toString()); + sb.setLength(0); sb.append(prefix); sb.append(" Wifi on: "); formatTimeMs(sb, wifiOnTime / 1000); |