Problem Summary:
I have IMX8M mcu for my custom board and android 11 device. When I manually write a value to (from 0 to 100) "/sys/class/backlight/backlight/brightness" using echo, the screen brightness changes immediately as expected. However, when I try to adjust the brightness through the Android Settings UI (Display > Brightness Slider), the brightness does not change at all.
This suggests that the system UI can update the brightness value internally but fails to correctly communicate with the backlight driver.
My Question:
What could be causing the Android brightness slider to not affect the actual hardware brightness, even though manual control through /sys works fine?
Some useful outputs
smarc_mx8mq:/ # getprop | grep light
[hw.backlight.dev]: [backlight]
[init.svc.vendor.light-default]: [running]
[init.svc_debug_pid.vendor.light-default]: [360]
[ro.boottime.vendor.light-default]: [16274638205]
[ro.hardware.lightsensor]: [/sys/class/i2c-dev/i2c-0/device/0-0044/]
[vendor.ro.lightsensor.threshold]: [20]
smarc_mx8mq:/ #
smarc_mx8mq:/ # ps -A | grep light
system 360 1 8677484 4172 binder_thread_read 0 S android.hardware.lights-service.example
Hello,
Could it be permission? since you are doing as kernel mode, when you are in the app its user mode.
Regards
There is no any permission issue. I have check avc logs and there is nothing. I have these debug logs which might be helpful.
smarc_mx8mq:/ $ getprop | grep light
[hw.backlight.dev]: [backlight]
[init.svc.vendor.light-default]: [running]
[init.svc_debug_pid.vendor.light-default]: [353]
[ro.boottime.vendor.light-default]: [17561009565]
[ro.hardware.lightsensor]: [/sys/class/i2c-dev/i2c-0/device/0-0044/]
[vendor.ro.lightsensor.threshold]: [20]
smarc_mx8mq:/ $
also, init rc has this definiton
# Default backlight device
setprop hw.backlight.dev "backlight"
# Chmod/chown FSL specific sys entry
chown system system /sys/class/backlight/backlight/brightness
chmod 0660 /sys/class/backlight/backlight/brightness
this is all ı know. I have seen similar issues but there is no result. Please help me ? Can it be HAL issue ? Where should ı check ?