Bug 493026 - Keyboard volume wheel affected by key press delay
Summary: Keyboard volume wheel affected by key press delay
Status: REPORTED
Alias: None
Product: kwin
Classification: Plasma
Component: input (show other bugs)
Version: 6.1.5
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-09-12 18:00 UTC by astroty.br
Modified: 2024-09-30 18:57 UTC (History)
7 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
sudo libinput debug-events &> keyboard.log (3.16 KB, text/plain)
2024-09-19 20:56 UTC, astroty.br
Details
Image of setting panel showing Delay setting location (161.30 KB, image/png)
2024-09-19 22:12 UTC, astroty.br
Details

Note You need to log in before you can comment on or make changes to this bug.
Description astroty.br 2024-09-12 18:00:20 UTC
Debug process
I got myself a new mechanical keyboard (Redragon Horus) after my old one broke and noticed that the scroll wheel doesn't work as it should. I use KDE Wayland so I went to the keyboard settings, changed the delay between key repeating and suddenly it was scrolling properly. This same issue didn't happen on my previous keyboard (Corsair K70, Red led version) nor does it happen on windows.

When I plug it in I get this message, showing multiple event devices

usb 3-14: USB disconnect, device number 11
usb 3-14: new full-speed USB device number 12 using xhci_hcd
usb 3-14: New USB device found, idVendor=258a, idProduct=0049, bcdDevice= 1.03
usb 3-14: New USB device strings: Mfr=1, Product=2, SerialNumber=0
usb 3-14: Product: Gaming Keyboard
usb 3-14: Manufacturer: BY Tech
input: BY Tech Gaming Keyboard as /devices/pci0000:00/0000:00:14.0/usb3/3-14/3-14:1.0/input/input45
input: BY Tech Gaming Keyboard System Control as /devices/pci0000:00/0000:00:14.0/usb3/3-14/3-14:1.1/0003:258A:0049.0014/input/input46
input: BY Tech Gaming Keyboard Consumer Control as /devices/pci0000:00/0000:00:14.0/usb3/3-14/3-14:1.1/0003:258A:0049.0014/input/input47
input: BY Tech Gaming Keyboard as /devices/pci0000:00/0000:00:14.0/usb3/3-14/3-14:1.1/0003:258A:0049.0014/input/input49
input: BY Tech Gaming Keyboard Mouse as /devices/pci0000:00/0000:00:14.0/usb3/3-14/3-14:1.1/0003:258A:0049.0014/input/input50
hid-generic 0003:258A:0049.0014: input,hiddev1,hidraw4: USB HID v1.11 Keyboard [BY Tech Gaming Keyboard] on usb-0000:00:14.0-14/input1

By using evtest I was able to confirm that Consumer Control is the one in charge of managing the volume wheel.
Is there anything I can do to fix this problem? The huge delay for the volume wheel really makes it hard to use and since my old keyboard worked just fine, I'm sure this must be a problem specific to this model 

STEPS TO REPRODUCE
1. Use the volume wheel present on the keyboard continously

OBSERVED RESULT
Wheel changes the volume, pauses, then after the delay time is set it starts changing the volume again

EXPECTED RESULT
Wheel changes the volume without delay

SOFTWARE/OS VERSIONS
Linux/KDE Plasma:  Archlinux
KDE Plasma Version:  6.1.5
KDE Frameworks Version: 6.5.0
Qt Version: 6.7.2

ADDITIONAL INFORMATION
Keyboard idVendor=258a, idProduct=0049
Comment 1 Nate Graham 2024-09-16 17:50:19 UTC
So your keyboard includes a mechanical volume wheel, and the wheel is counted as a keyboard key such that it inappropriately respects the key repeat settings? Do I have that right?
Comment 2 astroty.br 2024-09-16 18:20:55 UTC
(In reply to Nate Graham from comment #1)
> So your keyboard includes a mechanical volume wheel, and the wheel is
> counted as a keyboard key such that it inappropriately respects the key
> repeat settings? Do I have that right?

Yes that's exactly right.
Comment 3 Nate Graham 2024-09-17 16:45:19 UTC
Fascinating, thanks. Seems very relevant to the input goal.
Comment 4 Zamundaaa 2024-09-19 20:38:38 UTC
I have a Logitech keyboard with a volume wheel, and it works correctly out of the box, and independently of key repeat settings. It does sound like your keyboard might need some special quirks in libinput or the kernel to deal with this.

Could you record the events of using the wheel a bit with
> sudo libinput debug-events
and attach the output here, so that we can figure out what exactly is happening?
Comment 5 astroty.br 2024-09-19 20:56:10 UTC
Created attachment 173896 [details]
sudo libinput debug-events &> keyboard.log

Run command, then move volume wheel, then Ctrl+C
Comment 6 Zamundaaa 2024-09-19 21:24:53 UTC
odd, that looks exactly like with my keyboard. This shouldn't be affected by key repeat settings at all.
Could you expand on which exact setting makes it work and which makes it not work?
Comment 7 astroty.br 2024-09-19 22:12:25 UTC
Created attachment 173897 [details]
Image of setting panel showing Delay setting location

Setting that affected my issue
Comment 8 astroty.br 2024-09-30 18:57:32 UTC
Is there any more information I could provide?