I have Ubuntu Mate installed on RPi3 with official 7" screen.

I was changing screen brightness through Mate's GUI where I dragged the bar too much towards the dark side... Resulting BLACK LCD!!!

How can I revert this? I can remove the microSD and mount it, but not sure where settings are stores (directory /sys is empty when I mount through Windows).

Any ideas?

  • 1
    "directory /sys is empty when I mount through Windows" -> Yes, it's just a mount point for a kernel interface. The file nodes inside while the system is running are abstractions; they aren't stored anywhere (note usually the size is 0). – goldilocks Dec 29 '16 at 9:09

You could simply insert the SD card back in your RPi and try to get a signal over SSH or normal HDMI. After that you can activate the backlight with

echo 0 > /sys/class/backlight/rpi_backlight/bl_power

I don't know if this also works with ubuntu mate, but it worked with raspbian.

  • 2
    As a note for people unfamiliar with sysfs, this will only work while the system is up and running. – goldilocks Dec 29 '16 at 9:07
  • This is why I mentioned that when I mount my SD card on other device it is displaying /sys as an empty folder. – HelpNeeder Dec 29 '16 at 16:46

This is how I check brightness level AFTER login, which is not perfect... But my device does perform auto login functionality. To make this work I must edit /etc/sudoers.d file like so:

user ALL=(root) NOPASSWD: /home/user/Desktop/scripts/brightness.sh

And following scripts into my Startup applicaitons:


if [ $EUID -ne 0 ]; then
    printf 'Script requires root...\n\r'
    max=$(< ${path}'max_brightness')
    value=$(< ${path}'brightness')

    if [ $# -ne 0 ]; then # setting value

        if [ $input -eq $input ] 2>/dev/null; then
            # checking for min
            if [ $input -lt $min ]; then

            # checking for max
            if [ $input -gt $max ]; then

            printf "\n\rChanging brightness to: ${input}\n\r\n\r"       
            ( echo $input | sudo tee ${path}brightness ) > /dev/null
            printf '\n\rIncorrect input...\n\r\n\r'
    else # repairing black screen
        if [ $value -lt  $min ]; then
            printf '\n\rValue is too low... Increasing brightness to: '

            ( echo $max | sudo tee ${path}brightness ) > /dev/null

            printf 'Brightness ok...\n\r'

exit 0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.