7

Got proprietary Nvidia drivers installed by Ubuntu itself, graphic card is recognized well by the system yet brightness control does not work when adjusted by either FN + F5/6 shortcut or by dragging brightness slider manually (keyboard shortcut triggers slider move as well, so it's heard by the system).

However: xrandr | grep " connected" | cut -f1 -d " " produces single output DP-2 and xrandr --output DP-2 --brightness 0.7 does change the brightness.

Googled a lot, tried various options, neither works to me. What can I do to make it work when dragging the slider as well?

Zazaeil
  • 257
  • 2
  • 9
  • Do you by any chance have `acpi=off` or `noacpi` in your grub boot parameters, which would have the effect of disabling your FN+function key controls? – Enterprise Jun 06 '20 at 16:34
  • Nope. Config is good and all the FNs are working. – Zazaeil Jun 06 '20 at 16:34
  • What does `ls /sys/class/backlight` reveal? On a laptop the hardware brightness is what FN keys control. Using `xrandr` is software control primarily used for external monitors not built in laptop displays. – WinEunuuchs2Unix Jun 06 '20 at 16:52
  • @WinEunuuchs2Unix acpi_video0. What does that mean? – Zazaeil Jun 06 '20 at 16:58
  • @SerejaBogolubov See if this helps: [nvidia backlight brightness problem](https://askubuntu.com/questions/935585/nvidia-backlight-brightness-problem) – WinEunuuchs2Unix Jun 06 '20 at 17:11

2 Answers2

7

So, finally - after trying lots and lots of options - following helped me: At the /usr/share/X11/xorg.conf.d folder find file related to your nvidia and append following section:

Section "Device"
    Identifier "Device0"
    Driver "nvidia"
    VendorName "NVIDIA Corporation"
    BoardName "<your graphic card as it named in your system>"
    Option "RegistryDwords" "EnableBrightnessControl=1"
EndSection

You can find the name of your graphic by searching for "system" in your Ubuntu. In my case it is GeForce GTX 1660 Ti so in abovementioned configuration file it gonna be BoardName "GeForce GTX 1660 Ti" - enclosed in doublequotes.

Save and reboot.

Zazaeil
  • 257
  • 2
  • 9
1
  1. Run nvidia-settings

  2. Select X Server Display Configuration

  3. Click Save to X Configuration File (don't click Save on opened dialog)

  4. Click Show preview...

  5. Copy Section "Device" ... EndSection (maybe you will need to copy Monitor and Screen sections)

  6. Create file /usr/share/X11/xorg.conf.d/10-nvidia-settings.conf and paste copied text in it, add to Device section Option "RegistryDwords" "EnableBrightnessControl=1", save file

  7. Add to file /etc/initramfs-tools/modules

    nvidia
    nvidia-drm
    nvidia-modeset
    
  8. Run sudo update-initramfs -u

  9. Restart

If you played with file /etc/default/grub than try to remove all acpi... settings from GRUB_CMDLINE_LINUX_DEFAULT=

Description about steps 7 and 8 is here

zx485
  • 2,249
  • 11
  • 24
  • 34
redexp
  • 111
  • 3