I tryed ubuntu 14.04 and 15.10, but I can't change the brightness. It is always on maximum.
The simplest way is to use a program called
xbacklight , open your terminal and type this
sudo apt-get install xbacklight
Brightness range can go upto 100 from 0 .
xbacklight -set 50 to set brightness to 50 from 100.
you can also increase and decrease the brightness from present value to specified level if you want to increase to 10% from current value of brightness then you can give this
xbacklight -inc 10
and to decrease 10% you can give this
xbacklight -dec 10
You can try to change grub configuration file. Open it
sudo nano /etc/default/grub
and go to the following line:
Now, next step depend on your computer. Try to change the above line, with one of the following:
GRUB_CMDLINE_LINUX_DEFAULT=”quiet splash acpi_backlight=vendor” GRUB_CMDLINE_LINUX_DEFAULT=”quiet splash acpi_osi=Linux acpi_backlight=legacy” GRUB_CMDLINE_LINUX_DEFAULT=”quiet splash acpi_osi=Linux” GRUB_CMDLINE_LINUX_DEFAULT=”quiet splash acpi_osi=”
Every time that you edit
/eft/default/grub file you have to run the following command that will apply changes.
To see results you have to reboot your system.
If the previous solution doesn't change your situation, you can try to do 2 things:
- update your kernel
- use a workaround
Update your kernel to latest Ubuntu version
sudo apt-get update sudo apt-get install linux-image-generic
Make a script to increment your brightness and one to decrement and bind them to a shortcut. You can try to use mine that I'm using on my PC.
#! /bin/bash # get max brightness and actual brighness MAX=`cat /sys/class/backlight/intel_backlight/max_brightness` AC_BR=`cat /sys/class/backlight/intel_backlight/brightness` # grow brightness of 5% AC_BR=$((MAX / 100 * 5 + AC_BR)) # check if i can set new brightness if (($AC_BR <= $MAX)); then echo $AC_BR > /sys/class/backlight/intel_backlight/brightness fi
#! /bin/bash # get max brightness and actual brighness MAX=`cat /sys/class/backlight/intel_backlight/max_brightness` AC_BR=`cat /sys/class/backlight/intel_backlight/brightness` # decrease brightness of 5% AC_BR=$((AC_BR - MAX / 100 * 5)) # check if i can set new brightness if (($AC_BR > 0)); then echo $AC_BR > /sys/class/backlight/intel_backlight/brightness else echo 5 fi
Copy the two bash scripts in two different file and give them execution permission:
chmod +x <file_name>
Move two script into your local bin directory to let you access to them everywhere in terminal:
sudo mv <file_brightness_up> <file_brightness_down> /usr/local/bin
Now you are ready to bind the scripts with shortcut. From System Setting select Keyboard and then Shortcuts. Select from the list on the left Custom Shortcuts and press Add shortcut button (+). Insert something as name and
<file_brightness_up> file name as command and save.
Then double click on right column and press your preferred shortcut.
Do the same for brightness down script.
To be sure that script works you have to change brightness file owner. So open
sudo nano /etc/rc.local
and add the following line before
chown <username>:<username> /sys/class/backlight/intel_backlight/brightness
Where is your user name. Reboot your system to apply changes.
It should work because also your PC have an Intel graphic card. So you should get actual brightness value with:
I hope this could help you.