From 5c01c78ce066bfdf3ca37a5d161cb1dd6425e884 Mon Sep 17 00:00:00 2001 From: Ken Tsou Date: Fri, 9 Dec 2022 15:55:54 +0800 Subject: [PATCH] battery: disable wireless for pts battery test Disable wireless charging during drain, usb charging, and charger stress test - vendor.disable.wlc 1 If device is placed onto dreamliner and shutdwon(drain out), it would boot up by DC_CHG and keep shutdown(0%)-boot up (by DC_CHG) continuously. To avoid this symptom, limit wireless current_max as 75000 after device boot up - persist.vendor.limit.wlc.current=1 How to verify: adb shell setprop vendor.disable.wlc 1 adb shell cat /sys/class/power_supply/wireless/online >>>> 0 adb shell setprop persist.vendor.limit.wlc.current 1 adb shell cat /sys/class/power_supply/dc/current_max >>>> 75000 Bug: 230549765 Test: set the property manually and query the result from file node. Change-Id: I5bcf9baeb2818b439520167b518b2e5c5224d7e2 Signed-off-by: Ken Tsou (cherry picked from commit 7d63c3ba7525e017ac02f887bd474ee9bdab45fc) --- device-felix.mk | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/device-felix.mk b/device-felix.mk index 736ce8e..d3428c9 100644 --- a/device-felix.mk +++ b/device-felix.mk @@ -308,6 +308,12 @@ PRODUCT_PROPERTY_OVERRIDES += \ PRODUCT_PRODUCT_PROPERTIES += \ persist.bluetooth.opus.enabled=true +# WLC userdebug specific +ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) + PRODUCT_COPY_FILES += \ + device/google/gs201/init.hardware.wlc.rc.userdebug:$(TARGET_COPY_OUT_VENDOR)/etc/init/init.wlc.rc +endif + # Biometrics virtual HAL for e2e testing PRODUCT_PACKAGES_DEBUG += \ android.hardware.biometrics.fingerprint-service.example