From f78d12b27824ef169d592d444487a53974296520 Mon Sep 17 00:00:00 2001 From: pjgowtham Date: Sun, 3 Nov 2024 10:07:56 +0530 Subject: [PATCH] ferrari: Set stock brightness levels Minimum brightness is obtained from stock by disabling auto-brightness and operating the brightness slider to minimum with running cat /sys/class/backlight/panel0-backlight/brightness This fetches a value of 4, the value that we currently have is 4/2047. However, the display dtsi exposes the range of 1 - 4095, so 4/4095 is being applied. The same value is applied for both dim and doze. Default brightness setting is applied as 1023/4095 Change-Id: I0b2513be866728f3ddf93f7fbe296d78d862c813 --- .../res/values/config.xml | 31 +++++++++++-------- 1 file changed, 18 insertions(+), 13 deletions(-) diff --git a/overlay/OPlusFrameworksResTarget/res/values/config.xml b/overlay/OPlusFrameworksResTarget/res/values/config.xml index 09935a5..f97afc1 100644 --- a/overlay/OPlusFrameworksResTarget/res/values/config.xml +++ b/overlay/OPlusFrameworksResTarget/res/values/config.xml @@ -343,27 +343,32 @@ 255 - - 6 - - - 0.45882353 + Set this to 0.0 to allow screen to go to minimal brightness. + The user is forbidden from setting the brightness below this level. --> + 0.0009768 - 1.0 + 1.0 - - 0.001954079 + Must be in the range specified by minimum and maximum. --> + 0.2498 + + + 0.0009768 + + + 0.0009768