View previous topic :: View next topic |
Author |
Message |
Markand Tux's lil' helper
Joined: 11 Jun 2008 Posts: 76
|
Posted: Thu Dec 07, 2017 2:04 pm Post subject: [Solved] Keyboard randomly generate XF86WakeUp codes in KDE |
|
|
Hello,
I have a Cherry Strait 3.0 black keyboard.
It works fine on any WM (dwm, pekwm), but on KDE I'm getting a curious behaviour, it randomly drop keystrokes so I sometimes need to type a key twice or more. It never happens on the internal laptop keyboard and an other USB one. I realized using xev that these keys are replaced with XF86WakeUp
I can reproduce it all the time using xev. I open xev, switch to a window and get back to xev input window test. If I type any key I get the following reports instead of the correct key:
Code: |
KeyPress event, serial 42, synthetic NO, window 0x3a00001,
root 0xf5, subw 0x0, time 1584761, (-2189,1390), root:(379,1439),
state 0x0, keycode 151 (keysym 0x1008ff2b, XF86WakeUp), same_screen YES,
XLookupString gives 0 bytes:
XmbLookupString gives 0 bytes:
XFilterEvent returns: False
KeyRelease event, serial 43, synthetic NO, window 0x3a00001,
root 0xf5, subw 0x0, time 1584769, (-2189,1390), root:(379,1439),
state 0x0, keycode 151 (keysym 0x1008ff2b, XF86WakeUp), same_screen YES,
XLookupString gives 0 bytes:
XFilterEvent returns: False
|
It never happens on a different WM than KDE.
Do you already have seen that before and have a solution?
Last edited by Markand on Fri Dec 08, 2017 10:40 am; edited 3 times in total |
|
Back to top |
|
|
Markand Tux's lil' helper
Joined: 11 Jun 2008 Posts: 76
|
Posted: Fri Dec 08, 2017 9:26 am Post subject: |
|
|
Using libinput-debug-events I can reproduce the problem.
I press some keyboard keys:
Code: |
-event8 KEYBOARD_KEY +2.68s *** (-1) pressed
e event8 KEYBOARD_KEY +2.74s *** (-1) released
event8 KEYBOARD_KEY +3.00s *** (-1) pressed
e event8 KEYBOARD_KEY +3.06s *** (-1) released
event8 KEYBOARD_KEY +3.37s *** (-1) pressed
e event8 KEYBOARD_KEY +3.44s *** (-1) released
event8 KEYBOARD_KEY +5.46s *** (-1) pressed
c event8 KEYBOARD_KEY +5.48s *** (-1) released
event8 KEYBOARD_KEY +5.80s *** (-1) pressed
c event8 KEYBOARD_KEY +5.86s *** (-1) released
event8 KEYBOARD_KEY +6.05s *** (-1) pressed
c event8 KEYBOARD_KEY +6.13s *** (-1) released
event8 KEYBOARD_KEY +6.41s *** (-1) pressed
event8 KEYBOARD_KEY +6.51s *** (-1) pressed
|
Now, I move the mouse, click and then I press a keyboard key:
Code: |
event15 POINTER_MOTION +3.01s 0.00/ -0.95
event15 POINTER_MOTION +3.03s 0.93/ -0.93
event15 POINTER_BUTTON +3.16s BTN_LEFT (272) pressed, seat count: 1
event15 POINTER_BUTTON +3.23s BTN_LEFT (272) released, seat count: 0
-event9 KEYBOARD_KEY +4.52s KEY_WAKEUP (143) pressed
event9 KEYBOARD_KEY +4.53s KEY_WAKEUP (143) released
|
A fancy KEY_WAKEUP appears with no reasons. |
|
Back to top |
|
|
Markand Tux's lil' helper
Joined: 11 Jun 2008 Posts: 76
|
Posted: Fri Dec 08, 2017 10:02 am Post subject: |
|
|
Okay, I've finally found.
At boot I have powertop --auto-tune which turns on agressive power management on USB devices. Not using it fixes the problem.
Use this tool with care |
|
Back to top |
|
|
Ant P. Watchman
Joined: 18 Apr 2009 Posts: 6920
|
Posted: Fri Dec 08, 2017 5:48 pm Post subject: |
|
|
I guess the keyboard's trying to be clever and thinks that if it's suspended the host is too, so only sends ACPI wakeup keys. Seems unnecessary too, every PC I've used will wake up on any key.
If your other USB devices work fine you may want to just blacklist that one in udev, like this:
/etc/udev/rules.d/local.rules: | ATTR{idVendor}=="xxxx", ATTR{idProduct}=="yyyy", ATTR{power/control}="on" |
|
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|