This makes it much easier to set your screen’s brightness to a comfortable level at each time of the day, and to save energy.

(For Windows, see the very bottom of this post.)

On Linux, if you currently have no keyboard shortcuts for that available, a good way to create them is via ddcutil. Once you have ddcutil installed, have your displays’ properties printed in the command line by typing ddcutil detect.

This should show you a list of parameters for each of the displays you have connected. For a display of your choice, try these commands:

ddcutil -n <Serial number> setvcp 10 - 5 # reduces brightness by 5 %
ddcutil -n <Serial number> setvcp 10 + 5 # increases brightness by 5 %

ddcutil -n <Serial number> setvcp 12 - 10 # reduces contrast by 10 %
ddcutil -n <Serial number> setvcp 12 + 10 # increases contrast by 10 %

ddcutil -n <Serial number> setvcp 10 0 # sets brightness to minimum
ddcutil -n <Serial number> setvcp 10 100 # sets brightness to maximum

If these commands all work, you can create in your desktop environment’s settings (e.g. KDE) custom keyboard shortcuts that execute these commands. Personally, with my two displays and with dedicated “Brightness up” and “Brightness down” keys (macros) on my keyboard, I am using combinations with the modifiers Alt to address the secondary instead of the primary display, Shift, to adjust contrast instead of brightness, and Control to set an absolute value (0% or 100%) instead of going by increments.


Further notes:

Instead of addressing your displays via their serial number, you can also address your display via most other parameters shown in ddcutil detect by using another option than -n, e.g. via bus number or manufacturer name, but I’ve found that bus number is not persistent over the years, and manufacturer name (“Mfg id”) may contain spaces which may lead to problems.

A full list of all other possible vcp commands (the numbers after setvcp) can be obtained through ddcutil vcpinfo.

If you’re using a laptop, brightness adjustments for its internal screen are of course almost always a no-brainer.


On Windows 10 and perhaps 11 as well, you can apparently do the following:

Step 1: Press the Win + A to open the Action Center.

Step 2: Press Shift + Tab to select the brightness slider.

Step 3: Use the left and right arrow keys to adjust the screen brightness.

  • 𞋴𝛂𝛋𝛆@lemmy.world
    link
    fedilink
    English
    arrow-up
    1
    ·
    17 hours ago

    Not as of a year or so back. I’m not sure how it works but there are several settings available in the manufacturer’s app that are not in Linux. Only the hotkey settings from the fn+ function keys work. Dmesg spits out a block of unrecognized memory that is something like 8 or 16 bits long that is the likely culprit. There is some odd microcontroller on a serial bus that is unrecognized too IIRC but that I have never seen before like any of the thousands found on LCSC. Last time I checked linux-hardware.org, it looked like no one had solved this one on any of the scans. I’m not motivated to chase it down myself. Poking some registers or watching for the changed location after using the built in hotkey would be peripherally interesting as a general thing to know.

    • Novocirab@feddit.orgOP
      link
      fedilink
      arrow-up
      2
      ·
      17 hours ago

      I feel you basically. I have given up trying to control the RGB on my RAM (even though it’s probably decently documented somewhere).