I am trying to identify scancodes for the three buttons below the space bar (above the trackpad) on my ThinkPad X1C6 using evtest
as well as evemu-record
. The buttons are working fine but no scancodes are reported.
Output:
Input driver version is 1.0.1
Input device ID: bus 0x11 vendor 0x2 product 0xa version 0x0
Input device name: "TPPS/2 Elan TrackPoint"
Supported events:
Event type 0 (EV_SYN)
Event type 1 (EV_KEY)
Event code 272 (BTN_LEFT)
Event code 273 (BTN_RIGHT)
Event code 274 (BTN_MIDDLE)
Event type 2 (EV_REL)
Event code 0 (REL_X)
Event code 1 (REL_Y)
Properties:
Property type 0 (INPUT_PROP_POINTER)
Property type 5 (INPUT_PROP_POINTING_STICK)
Testing ... (interrupt to exit)
Event: time 1582630481.910031, type 1 (EV_KEY), code 272 (BTN_LEFT), value 1
Event: time 1582630481.910031, -------------- SYN_REPORT ------------
Event: time 1582630482.071378, type 1 (EV_KEY), code 272 (BTN_LEFT), value 0
Event: time 1582630482.071378, -------------- SYN_REPORT ------------
Event: time 1582630483.486559, type 1 (EV_KEY), code 273 (BTN_RIGHT), value 1
Event: time 1582630483.486559, -------------- SYN_REPORT ------------
Event: time 1582630483.607941, type 1 (EV_KEY), code 273 (BTN_RIGHT), value 0
Event: time 1582630483.607941, -------------- SYN_REPORT ------------
Event: time 1582630488.204488, type 1 (EV_KEY), code 274 (BTN_MIDDLE), value 1
Event: time 1582630488.204488, -------------- SYN_REPORT ------------
emacs thinkpadEvent: time 1582630488.348561, type 1 (EV_KEY), code 274 (BTN_MIDDLE), value 0
Event: time 1582630488.348561, -------------- SYN_REPORT ------------
If I can capture the scancodes I intend to remap these buttons as CTRL and ALT keys using udev
hwdb if possible.
Some light on how to get the scan codes in such a case would be very much appreciated. BTW, I am on Ubuntu 18.04.4, Linux kernel 5.3.0-41-generic.
0 Answers