I can’t find out how to turn off the white led and the red led without going into the settings menu.
I want to do it using adb commands.
This worked, but only until reboot:
adb shell “echo 2 > /sys/class/redled/mode”
adb shell “echo none > /sys/class/leds/sys_led/trigger”
It seems Android just overwrites those settings on reboot.
The reason I want to change led config through adb is because we’re installing a lot of devices, and it takes a lot of time to connect a mouse and do it through the GUI.
This is the solution that worked:
adb shell setprop persist.sys.red.led.mode 2
adb shell setprop persist.sys.white.led.trigger 2
Then the leds will be off after reboot. Or if I want to turn the leds off immediately I can run these as well:
adb shell “echo 2 > /sys/class/redled/mode”
adb shell “echo off > /sys/class/leds/sys_led/trigger”