From 5b582d83e136f506c0d3fa9e86f64664598e62b8 Mon Sep 17 00:00:00 2001 From: matteo0026 Date: Mon, 5 Oct 2020 20:00:48 +0200 Subject: [PATCH] matisse-common: fixed offline charging * Wrong value of user_debug in cmdline prevented to try to boot in offline charging mode * For charger, tell that we don't have a LED and to disable init blank (with this flag, charging mode showed animation, but didn't allow to show it another time when pressing power button to turn on the screen) * Set a brightness value for charger. In this way, when power button is pressed, device turns on and shows battery icon correctly. Conflicts: BoardConfigCommon.mk --- BoardConfigCommon.mk | 6 +++++- rootdir/etc/init.target.rc | 2 ++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/BoardConfigCommon.mk b/BoardConfigCommon.mk index a6d44bd..8ca888d 100644 --- a/BoardConfigCommon.mk +++ b/BoardConfigCommon.mk @@ -44,6 +44,10 @@ BUILD_FINGERPRINT := samsung/matissewifixx/matissewifi:5.0.2/LRX22G/T530XXS1BRH1 # Camera TARGET_NEEDS_TEXT_RELOCATIONS := true +# Charger +BOARD_NO_CHARGER_LED := true +BOARD_CHARGER_DISABLE_INIT_BLANK := true + # Extended Filesystem Support TARGET_EXFAT_DRIVER := sdfat @@ -52,7 +56,7 @@ DEVICE_MANIFEST_FILE += $(COMMON_PATH)/manifest.xml # Kernel BOARD_KERNEL_BASE := 0x00000000 -BOARD_KERNEL_CMDLINE := console=null androidboot.hardware=qcom user_debug=23 msm_rtb.filter=0x37 zcache.enabled=1 +BOARD_KERNEL_CMDLINE := androidboot.hardware=qcom user_debug=23 msm_rtb.filter=0x37 zcache.enabled=1 zcache.compressor=lz4 BOARD_KERNEL_IMAGE_NAME := zImage BOARD_KERNEL_PAGESIZE := 2048 BOARD_KERNEL_SEPARATED_DT := true diff --git a/rootdir/etc/init.target.rc b/rootdir/etc/init.target.rc index d5a4cd1..484ffd3 100644 --- a/rootdir/etc/init.target.rc +++ b/rootdir/etc/init.target.rc @@ -87,3 +87,5 @@ on boot chmod 0640 /efs/gyro_cal_data restorecon /efs/gyro_cal_data +on charger + write /sys/class/leds/lcd-backlight/brightness 150