Brightness control keys not working on my i3WM install

Hi,

I just recently got installed my first EnOS-i3WM on a laptop. I am taking my first steps to learn and figure out how things work in a WM, in this case i3.

I am facing some issues that I am hopeful to resolve with your guidance and help.

First off: I don’t seem to be able to adjust the screen brightness. Usually F5 and F6 (without pressing Fn-key) works for decreasing and increasing the brightness. However they don’t work in my install of i3.

I came across the following post in another thread:

Here is the output of the command:

$ grep -i xf86 ~/.config/i3/config
bindsym XF86MonBrightnessUp exec xbacklight +10
bindsym XF86MonBrightnessDown exec xbacklight -10
bindsym XF86AudioRaiseVolume exec amixer -D pulse sset Master 5%+ && pkill -RTMIN+1 i3blocks
bindsym XF86AudioLowerVolume exec amixer -D pulse sset Master 5%- && pkill -RTMIN+1 i3blocks
#bindsym XF86AudioRaiseVolume exec pamixer -i 5 --allow-boost && dunstify -h string:x-dunst-stack-tag:volume volume: $(pamixer --get-volume)%
#bindsym XF86AudioLowerVolume exec pamixer -d 5 --allow-boost && dunstify -h string:x-dunst-stack-tag:volume volume: $(pamixer --get-volume)%
#bindsym XF86AudioMute exec pamixer -t && dunstify -h string:x-dunst-stack-tag:mute mute: $(pamixer --get-mute)!
bindsym $mod+XF86AudioRaiseVolume exec amixer -D pulse sset Master 1%+ && pkill -RTMIN+1 i3blocks
bindsym $mod+XF86AudioLowerVolume exec amixer -D pulse sset Master 1%- && pkill -RTMIN+1 i3blocks
#bindsym XF86AudioMute exec amixer sset Master toggle && killall -USR1 i3blocks
bindsym XF86AudioMute exec pamixer -t && notify-send "mute: $(pamixer --get-mute)"
bindsym XF86AudioPlay exec playerctl play
bindsym XF86AudioPause exec playerctl pause
bindsym XF86AudioNext exec playerctl next
bindsym XF86AudioPrev exec playerctl previous

I see the following lines related to brightness:

bindsym XF86MonBrightnessUp exec xbacklight +10
bindsym XF86MonBrightnessDown exec xbacklight -10

but I don’t know which keys on the keyboard they refer to.

Update:

I tried running xbacklight +10 in a terminal and got:
bash: xbacklight: command not found

So I went ahead and installed xorg-xbacklight. Yet the keys are not functioning.

By the way, shouldn’t xorg-xbacklight be part of the packages to be installed since the CL to be executed is used in the config file?

Update 2:

I tried to set the brightness via terminal:

$ xbacklight -set 0.20
No outputs have backlight property

Something else seems to be lacking on my setup. I would appreciate any hints/pointers to resolve this.

Edit:

Some more output (fwiw):

$ sudo find /sys/ -type f -iname '*brightness*' 
[sudo] password for pebcak: 
/sys/devices/platform/i8042/serio0/input/input3/input3::numlock/brightness
/sys/devices/platform/i8042/serio0/input/input3/input3::numlock/max_brightness
/sys/devices/platform/i8042/serio0/input/input3/input3::capslock/brightness
/sys/devices/platform/i8042/serio0/input/input3/input3::capslock/max_brightness
/sys/devices/platform/i8042/serio0/input/input3/input3::scrolllock/brightness
/sys/devices/platform/i8042/serio0/input/input3/input3::scrolllock/max_brightness
/sys/devices/pci0000:00/0000:00:14.3/PNP0C09:00/VPC2004:00/leds/platform::kbd_backlight/brightness
/sys/devices/pci0000:00/0000:00:14.3/PNP0C09:00/VPC2004:00/leds/platform::kbd_backlight/brightness_hw_changed
/sys/devices/pci0000:00/0000:00:14.3/PNP0C09:00/VPC2004:00/leds/platform::kbd_backlight/max_brightness
/sys/devices/pci0000:00/0000:00:08.1/0000:03:00.0/backlight/amdgpu_bl0/actual_brightness
/sys/devices/pci0000:00/0000:00:08.1/0000:03:00.0/backlight/amdgpu_bl0/brightness
/sys/devices/pci0000:00/0000:00:08.1/0000:03:00.0/backlight/amdgpu_bl0/max_brightness
/sys/devices/pci0000:00/0000:00:08.1/0000:03:00.3/usb1/1-2/1-2:1.0/0003:062A:4101.0003/input/input13/input13::scrolllock/brightness
/sys/devices/pci0000:00/0000:00:08.1/0000:03:00.3/usb1/1-2/1-2:1.0/0003:062A:4101.0003/input/input13/input13::scrolllock/max_brightness
/sys/devices/pci0000:00/0000:00:08.1/0000:03:00.3/usb1/1-2/1-2:1.0/0003:062A:4101.0003/input/input13/input13::numlock/brightness
/sys/devices/pci0000:00/0000:00:08.1/0000:03:00.3/usb1/1-2/1-2:1.0/0003:062A:4101.0003/input/input13/input13::numlock/max_brightness
/sys/devices/pci0000:00/0000:00:08.1/0000:03:00.3/usb1/1-2/1-2:1.0/0003:062A:4101.0003/input/input13/input13::capslock/brightness
/sys/devices/pci0000:00/0000:00:08.1/0000:03:00.3/usb1/1-2/1-2:1.0/0003:062A:4101.0003/input/input13/input13::capslock/max_brightness
/sys/devices/pci0000:00/0000:00:02.2/0000:01:00.0/leds/phy0-led/brightness
/sys/devices/pci0000:00/0000:00:02.2/0000:01:00.0/leds/phy0-led/max_brightness
/sys/module/video/parameters/hw_changes_brightness
/sys/module/video/parameters/brightness_switch_enabled
$ systemctl --all | grep backlight 
  sys-devices-pci0000:00-0000:00:08.1-0000:03:00.0-backlight-amdgpu_bl0.device                                                                                  loaded    active   plugged   /sys/devices/pci0000:00/0000:00:08.1/0000:03:00.0/backlight/amdgpu_bl0
  sys-devices-pci0000:00-0000:00:14.3-PNP0C09:00-VPC2004:00-leds-platform::kbd_backlight.device                                                                 loaded    active   plugged   /sys/devices/pci0000:00/0000:00:14.3/PNP0C09:00/VPC2004:00/leds/platform::kbd_backlight
  systemd-backlight@backlight:amdgpu_bl0.service                                                                                                                loaded    active   exited    Load/Save Screen Backlight Brightness of backlight:amdgpu_bl0
  systemd-backlight@leds:platform::kbd_backlight.service                                                                                                        loaded    active   exited    Load/Save Screen Backlight Brightness of leds:platform::kbd_backlight
  system-systemd\x2dbacklight.slice                                                                                                                             loaded    active   active    Slice /system/systemd-backlight
1 Like

on Pinebook pro no work … brightnessctl work

so could try

bindsym XF86MonBrightnessDown exec brightnessctl set 5%-
bindsym XF86MonBrightnessUp exec brightnessctl set +5%

check

pacman -Qi brightnessctl

my Fn+f1 down… Fn+F2 up

EDit i check my sway ( use now ) this in config

# Backlight
#
    bindsym XF86MonBrightnessUp exec brightnessctl -c backlight set +5%
    bindsym XF86MonBrightnessDown exec brightnessctl -c backlight set 5%-
#

EDit 2

Usage: brightnessctl [options] [operation] [value]

Options:
  -l, --list			list devices with available brightness controls.
  -q, --quiet			suppress output.
  -p, --pretend			do not perform write operations.
  -m, --machine-readable	produce machine-readable output.
  -n, --min-value		set minimum brightness, defaults to 1.
  -e, --exponent[=K]		changes percentage curve to exponential.
  -s, --save			save previous state in a temporary file.
  -r, --restore			restore previous saved state.
  -h, --help			print this help.
  -d, --device=DEVICE		specify device name (can be a wildcard).
  -c, --class=CLASS		specify device class.
  -V, --version			print version and exit.

Operations:
  i, info			get device info.
  g, get			get current brightness of the device.
  m, max			get maximum brightness of the device.
  s, set VALUE			set brightness of the device.

Valid values:
  specific value		Example: 500
  percentage value		Example: 50%
  specific delta		Example: 50- or +10
  percentage delta		Example: 50%- or +10%

hope it help

2 Likes

Indeed, it did! Awesome, thank you so much!

I needed to install brightnessctl and add those lines to ~/.config/i3/config. I chose 1% as I like to have a more fine grained tuning.

PS- I’ll change the title of the topic and mark it solved. I will create other threads for my other questions/issues.

4 Likes

i happy you got fix … Hope it no stop you use wm! it learn curve . worth it in end :wink:

4 Likes

Thanks @Shjim!

No way! With the fantastic support I get from you guys, I think I’ll be fine taking on the learning curve. So far so good and it’s lot of fun learning new things. It’s just that my brain is wired to do things differently in a full DE environment. But I just have to rewire it little by little every day.
:brain:

2 Likes

you welcome :+1:

2 Likes

One thing that helped me, is use a text editor and type in the keyboard shortcuts that you use most frequently. Print it out and put on your desk or keyboard as such.


Sorry the pic is a little dark.

Then when some of these become second nature, remove the well known ones, and replace with new shortcuts as you run across them.

Pudge

3 Likes

What a great tips!
Thanks @pudge! I certainly will put your method in practice. Sounds like a very efficient way to learn all those shortcuts.

1 Like

When a person is seventy one years old and dyslexic, visual aids are crucial. :persevere:

Pudge

3 Likes

a very very nice keyboard!

2 Likes

Wish I will have your cognitive capabilities when I am 71.

2 Likes

True that!

1 Like

The keyboard is made by Key Tronic. I don’t even think they are in business any more.

The first one I bought was a PS2 keyboard, it now sits in the closet.
I have four USB Key Tronic. I have never found a keyboard I like better. Plus, these things last forever.

Pudge

1 Like

It certainly looks great just judging by the picture. I’m sure it’s a joy typing on such a keyboard.
It seems that gone are the days that things were made to last. It’s quite sad given the state of the planet nowadays.

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.