enable volume control on keyboard

So kind of a hackish solution that works for me a while back with a (non-logitech) keyboard is to keybind the volume control key stroke events from the keyboard to the mixer audio utility. The guide I used can be found here

*edit I just remembered this guide was for openbox. The general process for determining the key code with xev should still work, but I do not know off the top of my head how to configure key-bindings for KDE...
 
Does anyone know how to enable volume control on keyboard? It worked with windows and linux systems.
Fisrt of all determine the keycodes using xev(1) (as mentioned by DiscmanDaemon), then create/modify file ~/.Xmodmap:
Code:
keycode XXX = XF86AudioLowerVolume
keycode YYY = XF86AudioRaiseVolume
This is a universal solution, not just for KDE. If KDE doesn't use ~/.Xmodmap automatically, you should add it to $KDEDIR/share/config/kdm/Xsession.
 
Fisrt of all determine the keycodes using xev(1) (as mentioned by DiscmanDaemon), then create/modify file ~/.Xmodmap:
Code:
keycode XXX = XF86AudioLowerVolume
keycode YYY = XF86AudioRaiseVolume
This is a universal solution, not just for KDE. If KDE doesn't use ~/.Xmodmap automatically, you should add it to $KDEDIR/share/config/kdm/Xsession.
xev doen't recognize my volume button press. It recognizes mouse movements and other buttons but not media buttons.
 
xev doen't recognize my volume button press. It recognizes mouse movements and other buttons but not media buttons.
Try loading iichid module (you'll probably need ig4, iicbus and iichid modules, YMMV). FreeBSD have this on base, for FreeBSD 12 and older, install sysutils/iichid.
 
Last edited by a moderator:
Fisrt of all determine the keycodes using xev(1) (as mentioned by DiscmanDaemon), then create/modify file ~/.Xmodmap:
Code:
keycode XXX = XF86AudioLowerVolume
keycode YYY = XF86AudioRaiseVolume
This is a universal solution, not just for KDE. If KDE doesn't use ~/.Xmodmap automatically, you should add it to $KDEDIR/share/config/kdm/Xsession.
I created .Xmodmap but it is not working. I am using dwm.
 
Back
Top