1

The brightness key (Fn + left/right arrows) on my Acer ASPIRE v15 laptop> on Ubuntu 16.04 LTS are not working.
I can control the brightness by changing the value of brightness by editing the file: /sys/class/backlight/intel_backlight/brightness

I want to connect the (Fn + arrow) key to a script which edits the value in the
above file. But acpi_listen does not detect the pressing of (fn + arrow(left or right)) key. Though, it is able to detect (fn + arrow(up or down)) keys for volume control.

How to get these keys detected for brightness control by the acpi?

Edit: Binding another keys(other than the (fn + arrow) and calling the script as non-acpi event forces me to run the script by placing it inside /etc/sudoers.d/ directory in order to avoid prompting for password at each press of the key. (as changing the value of brightness requires root permission).

3
  • 1
    Welcome to Ask Ubuntu. You haven't told us your release of Ubuntu, or your desktop (which may be the default, but without release we cannot know).
    – guiverc
    Feb 3, 2019 at 13:20
  • I am using Ubuntu 16.04 LTS .
    – rack_jack
    Feb 3, 2019 at 13:59
  • You don't need root privileges to change brightness Jan 10, 2021 at 21:08

2 Answers 2

0

At first we need some information about the video card. Just to make sure the right one is working. For example it is a APU (CPU+GPU in one processor). Intel or AMD does not matter. In my example it is an i5 470U processor. For further use we need the ID of the graphic card:

$ sudo lspci | grep VGA

--> 00:02.0 VGA compatible controller: Intel Corporation Core Processor 
    Integrated Graphics Controller (rev 02)
The ID is 0:2:0

For further information about the vide device use

$ sudo lshw -c video

We need to edit/create a config file for xorg:

/usr/share/X11/xorg.conf.d/20-intel.conf

For our example the following section has to be inserted:

Section "Device"
      Identifier "Intel Graphics"
      Driver "intel"
      Option "Backlight" "intel_backlight"
      BusID "PCI:0:2:0"
      EndSection
Section "Device"

Source: https://wiki.ubuntuusers.de/Grafikkarten/Intel/

Then the grub bootloader has to be edited to rewrite the list of supported OS. This Bios option was introduced during the time of windows vista.

Source: https://wiki.ubuntuusers.de/Bootoptionen/

Grub editieren and extend the following line with acpi_osi=Linux in

/etc/default/grub

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_osi=Linux"

Close file and update grub

$ sudo update-grub

Reboot the System.

$ reboot 

The keys (with the sun symbol) on your keyboard for regulating the brightness should work now.

2
  • (Thank you for the contributor who also made some correction of my post)
    – simageye
    Jan 11, 2021 at 4:24
  • tested with Ubuntu 20.04 lts und 16.04 lts.
    – simageye
    Jan 11, 2021 at 4:26
-1

In settings > Devices > Keyboards look for the hotkeys for controlling brightness. If your built in keys don't work, you can manually bind over them (Select the adjust brightness shortcut and press Fn + L/R)

2
  • I am unable to bind fn + l/r key through this method.
    – rack_jack
    Feb 3, 2019 at 18:25
  • It seems that acer doesnot support fully featured acpi for GNU/Linux. I am just going with running the script and linking to other keyboard short cuts.
    – rack_jack
    Feb 19, 2019 at 2:27

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .