Out-of-tree HID kernel module for the common USB sim handbrake that identifies as
LeafLabs Maple / 1eaf:0024.
The stock Linux HID mapping exposes confusing axes for this device. Based on the
captured HID descriptor and raw reports, the real handbrake signal is the second
10-bit slider field in report 0x14, while button 1 is exposed separately.
This module bypasses the generic HID input mapping and instead creates a clean
Linux input device named hid-chandbreak with:
BTN_TRIGGERABS_RZin the range0..1023
This first version is intentionally narrow:
- Vendor/Product:
1eaf:0024 - Report ID:
0x14 - One button (
data[1] bit 0) - One axis (
slider2from bits54..63ofdata[5..12])
The CachyOS kernel is built with the full LLVM toolchain (Clang + LLD), so the module must be built the same way. Using GCC or GNU ld will fail because the kernel's build flags contain LLVM-specific options.
make LLVM=1sudo insmod hid-chandbreak.koIf the device is already bound to hid-generic, manually rebind it:
- Find the HID device path:
ls /sys/bus/hid/devices
- Inspect candidates until you find the one with
1EAF:0024inuevent:grep -H . /sys/bus/hid/devices/*/uevent
- Override and rebind:
echo hid-chandbreak | sudo tee /sys/bus/hid/devices/<DEV>/driver_override echo <DEV> | sudo tee /sys/bus/hid/drivers/hid-generic/unbind echo <DEV> | sudo tee /sys/bus/hid/drivers/hid-chandbreak/bind
sudo evtestLook for a device named hid-chandbreak and verify that:
- pulling the handbrake changes
ABS_RZ - the end-stop button toggles
BTN_TRIGGER
- This module deliberately uses
HID_CONNECT_HIDRAWonly, so generic HID input mapping should not create duplicate axes. hidrawremains available for debugging.- A
dkms.confandPKGBUILDare included for permanent installation via DKMS or makepkg. - AI-sloped :)