HP-2137sl volume bar configuration

Like described in the previous post, find both codes for increase/decrease volume with xev:

KeyPress event, serial 34, synthetic NO, window 0x3400001,
root 0x15d, subw 0x0, time 979988, (423,-222), root:(1017,104),
state 0x10, keycode 122 (keysym 0x1008ff11, XF86AudioLowerVolume), same_screen YES,
XLookupString gives 0 bytes:
XmbLookupString gives 0 bytes:
XFilterEvent returns: False

KeyPress event, serial 34, synthetic NO, window 0x3400001,
root 0x15d, subw 0x0, time 978476, (423,-222), root:(1017,104),
state 0x10, keycode 123 (keysym 0x1008ff13, XF86AudioRaiseVolume), same_screen YES,
XLookupString gives 0 bytes:
XmbLookupString gives 0 bytes:
XFilterEvent returns: False

Add those codes to ~/.xmodmaprc file:

keycode 121 = F24
keycode 122 = F25
keycode 123 = F26

And the corrispondent commands to ~/.xbindkeysrc:

# Muto
"amixer -c 0 sset Speaker,0 toggle"
m:0x10 + c:121
Mod2 + F24

# Abbassa volume
"amixer -c 0 sset Master 5%-"
m:0x10 + c:122
Mod2 + F25

# Alza volume
"amixer -c 0 sset Master 5%+"
m:0x10 + c:123
Mod2 + F26

I’ve added this command at the end of ~/.bashrc to have the key bindings loaded when X start:

xbindkeys -f /home/simplex/.xbindkeysrc

That’s all.

Lascia un commento

Il tuo indirizzo email non sarà pubblicato. I campi obbligatori sono contrassegnati *