[SOLVED] Brightness steps control

Questions about hardware, drivers and peripherals
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
veggar
Level 1
Level 1
Posts: 6
Joined: Sat Nov 05, 2022 5:55 am

[SOLVED] Brightness steps control

Post by veggar »

Hello everyone,

I run LM 21 Mate edition on a Lenovo Yoga laptop.
I would like to reduce the screen brightness steps when I use Fn + Brightness up/down. The keys work well and brightness is adjusted when I press them but it takes me too many steps from the lowest level to the brightest level (i.e. I need to press the keys around 20 times to reach the maximum brightness). Which command do the keys call? xbacklight? Where to adjust it?
Thanks a lot!
Last edited by LockBot on Fri May 05, 2023 10:00 pm, edited 2 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
manyroads
Level 5
Level 5
Posts: 586
Joined: Wed Mar 30, 2011 11:14 am
Location: just around the corner
Contact:

Re: Brightness steps control

Post by manyroads »

You can use the mate-power-manager 'preference' to adjust brightness.
Pax vobiscum,
...mark
SwayWM, i3wm, bspwm, hlwm, dwm
Professional Genealogist & Technologist
(http://eirenicon.org & http://many-roads.com)
veggar
Level 1
Level 1
Posts: 6
Joined: Sat Nov 05, 2022 5:55 am

Re: Brightness steps control

Post by veggar »

Thanks for your reply, but it doesn't answer my question.
I would like to know how to reduce the steps it takes to adjust the screen brightness when I press Fn + Brightness up/down, not how to adjust power profiles.
Please, read again my post.
Cheers
veggar
Level 1
Level 1
Posts: 6
Joined: Sat Nov 05, 2022 5:55 am

Re: Brightness steps control

Post by veggar »

I still couldn't find how to adjust the steps on FN key presses but I have found a workaround, if anyone has the same need.

1. Install xbacklight (which wasn't already, so FN keys must use some other method):

Code: Select all

sudo apt install xbacklight
2. The command didn't work out of the box. In my case (Intel Graphics), I had to add an /etc/X11/xorg.conf file with the following content:

Code: Select all

Section "Device"
    Identifier  "Intel Graphics" 
    Driver      "intel"
    Option      "Backlight"  "intel_backlight"
EndSection
This should work for anyone who has intel_backlight inside /sys/class/backlight/

3. Log out and log back in.

4. Test xbacklight works:

Code: Select all

xbacklight -20%
5. If it works, just make new shortcuts with Keyboard Shortcuts (from Menu)

6. In my case I made 2 shortcuts as follows: /usr/bin/xbacklight -20% bound to "Mod4 (Win key) + -" and /usr/bin/xbacklight -20% bound to "Mod4 (Win key) + +". In my keyboard layout + and - keys are just under Fn up/down so it's quite convenient.
PS: I tried other shortcut combinations and they didn't work (such as Shift + Ctrl + Fn up/down). Perhaps they conflict with something else.

If you want a finer adjustment (+/- 5%) you can still use the normal Fn keys.

If anyone has a better solution, please let me know.
User avatar
SMG
Level 25
Level 25
Posts: 31776
Joined: Sun Jul 26, 2020 6:15 pm
Location: USA

Re: Brightness steps control

Post by SMG »

veggar wrote: Sun Nov 20, 2022 6:56 am2. The command didn't work out of the box. In my case (Intel Graphics), I had to add an /etc/X11/xorg.conf file with the following content:

Code: Select all

Section "Device"
    Identifier  "Intel Graphics" 
    Driver      "intel"
    Option      "Backlight"  "intel_backlight"
EndSection
This should work for anyone who has intel_backlight inside /sys/class/backlight/
It is unlikely your system was using the "intel" driver. Now it is because you created that file.

Nearly all computers with Intel graphics use the "modesetting" driver and not "intel". Intel maintains and optimizes the "modesetting" driver and we do not recommend switching one's system to use the "intel" driver.

On Cinnamon, I just click the battery icon in the panel and the brightness slider appears. I hold and drag the slider to make changes. It's much easier than pressing Fn keys. (It's part of the Power Management app.) I do not know if that option is available on MATE.
Image
A woman typing on a laptop with LM20.3 Cinnamon.
veggar
Level 1
Level 1
Posts: 6
Joined: Sat Nov 05, 2022 5:55 am

Re: [SOLVED] Brightness steps control

Post by veggar »

Hi SMG,

thanks for making me notice that.
On Mate I don't get a slider when clicking the battery icon but I still think a keyboard shortcut is faster than clicking and sliding, at least that's my preference!
Do you know of a way to use modesetting and defining an option in xorg.conf to make xbacklight work? Simply changing intel to modesetting does load the right driver but xbacklight refuses to work ("No outputs have backlight property") just like before... anything else I should change?
Thanks again
User avatar
SMG
Level 25
Level 25
Posts: 31776
Joined: Sun Jul 26, 2020 6:15 pm
Location: USA

Re: [SOLVED] Brightness steps control

Post by SMG »

veggar wrote: Sun Nov 20, 2022 11:56 amOn Mate I don't get a slider when clicking the battery icon but I still think a keyboard shortcut is faster than clicking and sliding, at least that's my preference!
I don't know that I have ever used the Fn keys for brightness on any computer so I am not used to using the keyboard for brightness.

If I open the Power Management app, there is a tab for Brightness with a slider there as well. I'm guessing MATE has something similar.
veggar wrote: Sun Nov 20, 2022 11:56 amDo you know of a way to use modesetting and defining an option in xorg.conf to make xbacklight work?
I do not normally make those changes so I am not aware of other options.
Image
A woman typing on a laptop with LM20.3 Cinnamon.
Locked

Return to “Hardware Support”