From c09bf830ccac6ae6bf4235303e7f75188352956d Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Thu, 14 May 2020 18:31:37 +0200 Subject: [PATCH] Some devices have multiple panels, including some with 0 brightness. Take the one with the highest brightness --- rw-system.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rw-system.sh b/rw-system.sh index 68eb172..bbf119a 100644 --- a/rw-system.sh +++ b/rw-system.sh @@ -701,4 +701,4 @@ resetprop service.adb.root 0 # This is for Samsung Galaxy devices with HBM FOD # On those devices, a magic Layer usageBits switches to "mask_brightness" # But default is 255, so set it to max instead -cat /sys/class/backlight/panel/max_brightness > /sys/class/lcd/panel/mask_brightness +cat /sys/class/backlight/*/max_brightness |sort -n |tail -n 1 > /sys/class/lcd/panel/mask_brightness