Add Battery time to location dumpsys

BUG:73494617

Test: Manual
Change-Id: I162831387e65eff9856be8befe2b53b12ebf45f2
This commit is contained in:
Siddharth Ray
2018-03-27 11:54:34 -07:00
parent 5b4a0d6751
commit b30c0b7477

View File

@@ -224,7 +224,9 @@ public class GnssMetrics {
s.append("GNSS_KPI_END").append("\n");
GpsBatteryStats stats = mGnssPowerMetrics.getGpsBatteryStats();
if (stats != null) {
s.append("Power Metrics").append('\n');
s.append("Power Metrics").append("\n");
s.append(" Time on battery (min): "
+ stats.getLoggingDurationMs() / ((double) DateUtils.MINUTE_IN_MILLIS)).append("\n");
long[] t = stats.getTimeInGpsSignalQualityLevel();
if (t != null && t.length == NUM_GPS_SIGNAL_QUALITY_LEVELS) {
s.append(" Amount of time (while on battery) Top 4 Avg CN0 > " +