In this post I’d like to show you how to adjust the Android Brightness using Adb. This could be particularly useful when for instance you accidentally set the brightness to small values, therefore you are not able to get back to a value that let you see what is going on.
The first step is to connect the Android devices to your PC using the mini-usb cable. On Windows, you have to install first the Android usb driver provided by Google (OEM) or by the device’s manufacturer. More info on that on this wiki. On Linux/Mac, no driver is needed.
Once the system recognises the device, get a remote shell by typing in a command terminal:
Now, you basically have to search for a specific file where the current android brightness is stored. For the Ltouch Android panels, you have to go directly to this folder:
from there, you can see all the files related to the device’s android brihtness.
If you’re not using the Ltouch panels, you have to search for good candidate in which the android brightness is stored. In order to do that, use the following procedure:
busybox find . -name “*brightness”
and you will get all the files in the device that end with the “brightness” string. Note that we have used busybox, that is a program that contains all the other linux-like commands that are not installed by default.
If you have a recent Android image, it is likely that the command find is already installed as default, therefore you do not need to use busybox.
Once a good folder candidate is found (maybe select the one that is close to the above directory), verify that in this directory there exists the file named “brightness”. If yes, type the following command
echo "255" > brightness
for setting the android brightness to the maximum. If you need to set it to other intermediate values, just modify the number 255 to some other values into the range [0,255].
What do you think? If you found it interesting, please share it! As usual, comments and suggestions are appreciated! Stay tuned!