Note : I know this question is becoming quite common, but I'm afraid every solution I found failed to solve the problem. Maybe the knowledge-base we have about this is getting old, irrelevant for newest hardware components ?
Linux 3.8.0-33-generic #48~precise1-Ubuntu SMP x86_64 x86_64 x86_64 GNU/Linux
I'm running Ubuntu 12.04 (Precise Pangolin) on a Sony VAIO, and the following AMD graphic card :
VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Thames [Radeon HD 7550M/7570M/7650M]
Most of the solutions I found where meant for Nvidia graphics, which is why I'm getting quite limited...
Basically, I can't change my brightness level.
- Using the GUI in
Brightness and lock, I can "change" the brightness value, but nothing actually happens.
- Using the Fn + F5/F6 keys triggers a desktop notification displaying the new brightness value, but still : nothing changes.
What I've tried
It's important to know that this problem hasn't been there forever. On my first Ubuntu install, everything was quite functional when it comes to brightness. Then, because I got quite bored of Ubuntu, I decided to switch to Arch Linux, and I'm now back on Ubuntu for my primary desktop machine. However now, setting the brightness is not possible anymore, which means I have to use my screen at full brightness everytime, even when I'm on battery...
As I said, I tried as many solutions as I was able to find :
- I edited the
GRUB_CMDLINE_LINUXGRUB setting, with
acpi_osi=Linux. Files were created into
max_brightness), but even though their content changes as I set my brightness higher or lower, no change is effective.
- Same thing, adding
/sys/class/backlight/acpi_video0link/directory disappeared. Control keys do not trigger notifications anymore, and changing the setting using the GUI is no longer possible.
- I tried using
xbacklight. No error, but no changes.
Has anyone got any experience with those problems ?
Here's the workaround I've made from S Prasanth's answer. Root terminal required.
/usr/bin/brightness_change file, I've placed this script :
#!/bin/bash if [ $# -ne 1 ]; then echo "Usage: brightness_change [level]" > /dev/stderr exit 1 fi if [ ! -w /sys/class/backlight/acpi_video0/brightness ]; then echo "Brightness settings are not available." > /dev/stderr exit 2 fi TIMEOUT=4 endTime=$(($(date +%s)+$TIMEOUT)) while [ $(date +%s) -lt $endTime ] do echo $1 | tee -a /sys/class/backlight/acpi_video0/brightness > /dev/null 2> /dev/null done
This script will NOT always give a satisfying result. It usually has to be run several times before succeeding. Also, remember to set its rights and ownership correctly :
chown root:root /usr/bin/brightness_change chmod 0755 /usr/bin/brightness_change
Now, in my
/etc/sudoers file :
ALL ALL=NOPASSWD: /usr/bin/brightness_change
This way, anyone can execute
sudo brightness_change without the need of a password.
For further improvements : you may want to connect this script to your ACPI events, in order to trigger a brightness change when your laptop goes on battery, on gets plugged-in.
Note : this problem seems to have been fixed in the newest versions of the driver, my hotkeys are now fully functional.