Changing monitor brightness using the Linux command line
Published on 11th August 2018 Estimated Reading Time: 1 minuteRecently, I needed to reduce my monitor brightness but could not make the hardware buttons work. Thus, I considered alternatives and discovered the xrandr
command was effective. First, I needed to identify my display name, so I executed the following command with the -q
query switch to retrieve this information:
xrandr -q | grep " connected"
The output from this looked like this:
DVI-D-0 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 521mm x 293mm
My device name appeared as the first block of characters in the above, so I plugged that into the second command below to achieve the desired adjustment.
xrandr --output DVI-D-0 --brightness 0.9
Any value between 0.0 and 1.0 is acceptable, but I went with 0.9 for 90% brightness. The required dimming and brightening then is only a command away.