Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1075)

Unified Diff: build/android/pylib/android_commands.py

Issue 617453004: [Telemetry] Support dumpsys power monitoring on the Nexus 5. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Revert stray change Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tools/telemetry/telemetry/core/platform/power_monitor/android_dumpsys_power_monitor.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/pylib/android_commands.py
diff --git a/build/android/pylib/android_commands.py b/build/android/pylib/android_commands.py
index 0a4b2f0e47348b60bffdc9a74536c980113aa9a5..ea86e6d90176beddca6f2f5c7217635793a09f72 100644
--- a/build/android/pylib/android_commands.py
+++ b/build/android/pylib/android_commands.py
@@ -78,6 +78,20 @@ CONTROL_USB_CHARGING_COMMANDS = [
'disable_command':
'echo 1 > /sys/module/pm8921_charger/parameters/disabled',
},
+ {
+ # Nexus 5
+ # Setting the HIZ bit of the bq24192 causes the charger to actually ignore
pasko 2014/10/14 09:16:22 Wow! Cool! How do I discover similar things for ne
+ # energy coming from USB. Setting the power_supply offline just updates the
+ # Android system to reflect that.
+ 'witness_file': '/sys/kernel/debug/bq24192/INPUT_SRC_CONT',
+ 'enable_command': (
+ 'echo 0x4A > /sys/kernel/debug/bq24192/INPUT_SRC_CONT && '
+ 'echo 1 > /sys/class/power_supply/usb/online'),
+ 'disable_command': (
+ 'echo 0xCA > /sys/kernel/debug/bq24192/INPUT_SRC_CONT && '
+ 'chmod 644 /sys/class/power_supply/usb/online && '
+ 'echo 0 > /sys/class/power_supply/usb/online'),
+ },
]
class DeviceTempFile(object):
« no previous file with comments | « no previous file | tools/telemetry/telemetry/core/platform/power_monitor/android_dumpsys_power_monitor.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698