Ubuntu – Lenovo Legion 5 15IMH05H brightness control problem

20.04backlightbrightnessdriversnvidia

I have a Lenovo Legion 5 15IMH05H with NVIDIA GeForce RTX 2060 6GB GDDR6/Intel Corporation UHD Graphics (rev 05) and an Intel Processor.
After dual booting windows and Ubuntu 20.04 I encountered a few issues with the changing the brightness. The brightness keys or slider don't work on Ubuntu but they have no problem on windows. I managed to change the brightness by installing the brightness controller app but it is not a perfect solution.
I found an intel_backlight folder in /sys/class/backlight and I tried changing the GRUB several times adding acpi_backlight = vendor, none or video after quick splash.
I also tried editing files in /usr/share/X11/xorg.conf.d like for example the 10-nvidia.conf and I tried creating a 20/80-intel.conf but nothing has worked so far.
It is perhaps worth noting that with intel conf solutions, sometimes vertical green lines appear on the background and the fonts become all blurry or missing. I had to use timeshift to return it to normal.
Here are some of the tutorials I have followed with none working:
https://itsfoss.com/fix-brightness-ubuntu-1310/
https://www.debugpoint.com/2016/10/2-ways-fix-laptop-brightness-problem-ubuntu-linux/
Brightness problem Ubuntu 18.04 LTS
If anyone has found another fix for the legion 5 or faced a similar issues please advise.

Best Answer

One method to control screen brightness that was not covered in the articles you linked to is through xrandr. Give this a try.

  1. Open Terminal
  2. Find the name of your display with: `xrandr | grep " connected" | cut -f1 -d " "
  3. Now set the brightness like this: xrandr --output {display} --brightness 0.7

On my Lenovo ThinkPad, this is what I get:

$ xrandr | grep " connected" | cut -f1 -d " "
eDP-1

Then to set the brightness to 70%:

$ xrandr --output eDP-1 --brightness 0.7

Hope this helps.

Related Question