From dda3824e84fa94cb3cadce324c589e648ca4fba6 Mon Sep 17 00:00:00 2001 From: Naveen Kumar Date: Sat, 29 Feb 2020 18:05:24 +0530 Subject: [PATCH 1/3] Added CPH1859 and CPH1861 for DT2W and Brightness fixes --- rw-system.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/rw-system.sh b/rw-system.sh index e55b5be..8acdbc5 100644 --- a/rw-system.sh +++ b/rw-system.sh @@ -129,7 +129,7 @@ changeKeylayout() { changed=true fi - if getprop ro.build.overlay.deviceid |grep -q -e RMX1931 -e CPH1859;then + if getprop ro.build.overlay.deviceid |grep -q -e RMX1931 -e CPH1859 -e CPH1861;then cp /system/phh/oppo-touchpanel.kl /mnt/phh/keylayout/touchpanel.kl chmod 0644 /mnt/phh/keylayout/touchpanel.kl changed=true @@ -161,7 +161,7 @@ mount -o remount,ro / || true for part in /dev/block/bootdevice/by-name/oppodycnvbk /dev/block/platform/bootdevice/by-name/nvdata;do if [ -b "$part" ];then - for devname in RMX1931 CPH1859;do + for devname in RMX1931 CPH1859 CPH1861;do if grep -q $devname $part;then setprop ro.build.overlay.deviceid $devname fi @@ -237,7 +237,7 @@ if getprop ro.vendor.build.fingerprint | grep -q -i \ setprop persist.sys.qcom-brightness "$(cat /sys/class/leds/lcd-backlight/max_brightness)" fi -if getprop ro.vendor.product.device |grep -iq -e RMX1801 -e RMX1803 -e RMX1807;then +if getprop ro.vendor.product.device |grep -iq -e RMX1801 -e RMX1803 -e RMX1807 -e CPH1859 -e CPH1861;then setprop persist.sys.qcom-brightness "$(cat /sys/class/leds/lcd-backlight/max_brightness)" fi From 3d3450c5daf67fbd93b4c37b9d0fa116951c7c74 Mon Sep 17 00:00:00 2001 From: Naveen Kumar Date: Sat, 29 Feb 2020 21:33:28 +0530 Subject: [PATCH 2/3] Adding Brightness and DT2W fix to CPH1859 and CPH1961 --- rw-system.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/rw-system.sh b/rw-system.sh index 8acdbc5..9fc03c5 100644 --- a/rw-system.sh +++ b/rw-system.sh @@ -241,6 +241,10 @@ if getprop ro.vendor.product.device |grep -iq -e RMX1801 -e RMX1803 -e RMX1807 - setprop persist.sys.qcom-brightness "$(cat /sys/class/leds/lcd-backlight/max_brightness)" fi +if getprop ro.build.overlay.deviceid |grep -q -e CPH1859 -e CPH1861;then + setprop persist.sys.qcom-brightness "$(cat /sys/class/leds/lcd-backlight/max_brightness)" +fi + if getprop ro.vendor.build.fingerprint | grep -iq \ -e Xiaomi/beryllium/beryllium -e Xiaomi/sirius/sirius \ -e Xiaomi/dipper/dipper -e Xiaomi/ursa/ursa -e Xiaomi/polaris/polaris \ From 1fb4bcbad66f91c0593339a35565a0516ac66d67 Mon Sep 17 00:00:00 2001 From: buddi56 <30726378+buddi56@users.noreply.github.com> Date: Sat, 29 Feb 2020 21:38:16 +0530 Subject: [PATCH 3/3] Fixed mistake --- rw-system.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rw-system.sh b/rw-system.sh index 9fc03c5..fc762c5 100644 --- a/rw-system.sh +++ b/rw-system.sh @@ -237,7 +237,7 @@ if getprop ro.vendor.build.fingerprint | grep -q -i \ setprop persist.sys.qcom-brightness "$(cat /sys/class/leds/lcd-backlight/max_brightness)" fi -if getprop ro.vendor.product.device |grep -iq -e RMX1801 -e RMX1803 -e RMX1807 -e CPH1859 -e CPH1861;then +if getprop ro.vendor.product.device |grep -iq -e RMX1801 -e RMX1803 -e RMX1807;then setprop persist.sys.qcom-brightness "$(cat /sys/class/leds/lcd-backlight/max_brightness)" fi