3

I've been trying for quite some time to map my audio controls to the corresponding XF86 keys. However,three keys: XF86AudioLowerVolume, XF86AudioRaiseVolume & XF86AudioMute refuse to work properly. After each login, I can press each of these keys exactly once. Afterwards, their input is repeated until I press another key or send another key signal. xev also shows a repeating keypress from these keys, and showkey shows only a keypress event, but no release. To clarify, this is what the output looks like:

keycode 113 press
keycode 114 press
keycode 115 press
 keycode  57 press
keycode  57 release

You can see that the spacebar (keycode 57) shows a release as expected, but keycodes 113-115 don't. Now I have looked all around on the internet, but I haven't seen another post in which only the key press is registered, and not the key release. I recently upgraded to ubuntu 19.10 and reinstalled xorg but to no avail. Any suggestions?


EDIT:

For all of the three keys, I only get an output in xev the first time I press it; the key is just repeated over and over again, like this:

KeyPress event, serial 34, synthetic NO, window 0x1e00001,
    root 0x168, subw 0x0, time 35686, (441,184), root:(1725,204),
    state 0x0, keycode 121 (keysym 0x1008ff12, XF86AudioMute), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyRelease event, serial 34, synthetic NO, window 0x1e00001,
    root 0x168, subw 0x0, time 36347, (441,184), root:(1725,204),
    state 0x0, keycode 121 (keysym 0x1008ff12, XF86AudioMute), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False
        ........

What surprises me is the line XLookupString gives 0 bytes:, that can't be right? Normal keys a single byte here, which corresponds to the output character. Other XF86 keys give me events like this:

KeymapNotify event, serial 157, synthetic NO, window 0x0,
    keys:  2   0   0   0   0   0   0   0   0   0   0   0   0   0   0   14  
           0   0   0   0   0   0   0   0   0   0   0   0   0   0   0   0   

Also, the keycodes that show up in xev to correspond to the correct bindings when I run xmodmap -pke. I am inclined to believe that the problem isn't with my X server, because restarting the X server with sudo systemctl restart display-manager does nothing for me, neither does relogging.

I've also tried restarting the keyboard with

xinput disable 'AT Translated Set 2 keyboard'; 
xinput enable 'AT Translated Set 2 keyboard'

but to no avail.

I've tried restarting the atkbd module (the keyboard controller) with commands such as modprobe -r atkbd only to receive messages like modprobe: FATAL: Module atkbd is builtin.

So far, the only way to press (and never release) those keys is to restart.

Perhaps it is important to tell that I run a dual booted system with GRUB2. In Windows, the keys work just fine. I guess they also do in the bios, although that's a little hard to test for volume keys.


EDIT 2:

I am using a Medion Erazer P6661 laptop with built-in keyboard. By listing my keyboard with xinput list-props 12, I get the following information:

Device 'AT Translated Set 2 keyboard':
    Device Enabled (167):   1
    Coordinate Transformation Matrix (169): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
    libinput Send Events Modes Available (289): 1, 0
    libinput Send Events Mode Enabled (290):    0, 0
    libinput Send Events Mode Enabled Default (291):    0, 0
    Device Node (292):  "/dev/input/event4"
    Device Product ID (293):    1, 1
Pudding
  • 161
  • I'm using a Medion Erazer P6661 laptop with built-in keyboard, and yes I do use the Fn-keys to access these. I just found out that there are more keys which don't function properly, such as the XF86Sleep key, although I don't ever use that one. Almost all of them - brightness up- and down, etc., function properly. – Pudding Nov 20 '19 at 09:28
  • 1
    Probably the only thing that comes to my mind that I would do if that was my laptop is updating BIOS (UEFI) .. see download page But it appears they provide the BIOS package only for Windows10. – Vlastimil Burián Nov 20 '19 at 09:43
  • I ended up just updating my BIOS via windows to version 2.22, which didn't fix the problem. However, now my touchpad also doesn't work anymore! Perhaps related is that when running xinput, the touchpad now has id 12 (earlier beloning to the keyboard) and the keyboard is shifted up to id 13. – Pudding Nov 20 '19 at 10:20
  • I resolved the touchpad issue following the instructions here. Still haven't gotten the function keys working, though. – Pudding Nov 20 '19 at 14:05
  • I'm glad the touchpad is only a kernel bug and has a workaround! – Vlastimil Burián Nov 20 '19 at 14:13

0 Answers0