The solution for me was to edit the /etc/X11/xorg.con
f file. It's a problem with the graphics driver not the keymap.
Open the file for editing and add the line
Option "RegistryDwords" "EnableBrightnessControl=1"
in the Section "Device"
section as shown below.
Section "Device"
Identifier "Device0"
Driver "nvidia"
VendorName "NVIDIA Corporation"
Option "RegistryDwords" "EnableBrightnessControl=1"
Option "NoLogo" "True"
EndSection
To get working brightness key. try following
execute sudo gedit /etc/default/grub
Change this line
GRUB_CMLINE_LINUX_DEFAULT="quiet splash"
to something like below
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_osi=Linux acpi_backlight=vendor"
Execute sudo update-grub
and reboot . See if brightness keys are working.
It is still possible ubuntu won't remember your brightness settings. So you have to change brightness each time.
Please let us know the result as many sony users are facing this problem.
Update: This is for setting brightness manually.
Try following for both path shown by ls /sys/class/backlight/*/brightness
and replace accordingly. Most probably the intel one should work.
Get the maximum brightness:
cat /sys/class/backlight/intel_backlight/max_brightness
Try a lower value to set the brightness, say output is 2048 so I will try with half of it
echo 1024| sudo tee /sys/class/backlight/intel_backlight/brightness
If this works, make this happen in each login automatically by doing the following
sudo gedit /etc/rc.local
Enter this line just before exit 0
. It should look like
echo YOUR_VALUE_HERE > /sys/class/backlight/intel_backlight/brightness
exit 0
I have another question. Does your system has hybrid graphics card? whats the output of lspci | grep vga
?
Also you can try with xdotool
Best Answer
LCD Brightness Control
Once you have installed the proprietary Nvidia drivers as suggested above, you may notice that your brightness control keys do not work properly. This is fixable by editing one's xorg.conf file. Open a terminal window and type the following:
This will open your X server configuration (after prompting for your password). You should see a section titled "Device" that looks as follows:
Append a line so it appears like this:
You will need to restart your graphical server (or reboot) for this change to take effect.