xmodmap 키코드 매핑을 사용하여 쉽게 다시 매핑할 수 있는 고유 키코드 대신 ctrl+a
F2 , F3, F4 키가 각각 이벤트를 보내는 키보드가 있습니다 ctrl+c
.ctrl+v
내 목표는 키보드의 Fn 수정자를 누르지 않고도 미디어 키 대신 키보드의 기능 키를 기능 키로 사용하는 것입니다. 기본적으로 키보드는 FN 키를 보내는 내장 FN 스위치를 지원하지 않는 것 같습니다.
이 매핑을 어떻게 구현할 수 있나요?
xev 로그를 보면 다음 이벤트를 구별할 수 없는 것으로 보입니다.
실제 ctrl+a
버튼:
KeyPress event, serial 33, synthetic NO, window 0x2a00001,
root 0x79a, subw 0x0, time 59266583, (648,900), root:(648,900),
state 0x0, keycode 66 (keysym 0xffe3, Control_L), same_screen YES,
XKeysymToKeycode returns keycode: 37
XLookupString gives 0 bytes:
XmbLookupString gives 0 bytes:
XFilterEvent returns: False
KeyPress event, serial 36, synthetic NO, window 0x2a00001,
root 0x79a, subw 0x0, time 59266869, (647,899), root:(648,900),
state 0x4, keycode 38 (keysym 0x61, a), same_screen YES,
XLookupString gives 1 bytes: (01) ""
XmbLookupString gives 1 bytes: (01) ""
XFilterEvent returns: False
KeyRelease event, serial 36, synthetic NO, window 0x2a00001,
root 0x79a, subw 0x0, time 59266989, (647,899), root:(648,900),
state 0x4, keycode 38 (keysym 0x61, a), same_screen YES,
XLookupString gives 1 bytes: (01) ""
XFilterEvent returns: False
KeyRelease event, serial 36, synthetic NO, window 0x2a00001,
root 0x79a, subw 0x0, time 59266989, (647,899), root:(648,900),
state 0x4, keycode 66 (keysym 0xffe3, Control_L), same_screen YES,
XKeysymToKeycode returns keycode: 37
XLookupString gives 0 bytes:
XFilterEvent returns: False
F2 키 누르기:
KeyPress event, serial 33, synthetic NO, window 0x2a00001,
root 0x79a, subw 0x0, time 59337346, (648,900), root:(648,900),
state 0x0, keycode 37 (keysym 0xffe3, Control_L), same_screen YES,
XLookupString gives 0 bytes:
XmbLookupString gives 0 bytes:
XFilterEvent returns: False
KeyPress event, serial 33, synthetic NO, window 0x2a00001,
root 0x79a, subw 0x0, time 59337346, (648,900), root:(648,900),
state 0x4, keycode 38 (keysym 0x61, a), same_screen YES,
XLookupString gives 1 bytes: (01) ""
XmbLookupString gives 1 bytes: (01) ""
XFilterEvent returns: False
KeyRelease event, serial 36, synthetic NO, window 0x2a00001,
root 0x79a, subw 0x0, time 59337451, (648,900), root:(648,900),
state 0x4, keycode 37 (keysym 0xffe3, Control_L), same_screen YES,
XLookupString gives 0 bytes:
XFilterEvent returns: False
KeyRelease event, serial 36, synthetic NO, window 0x2a00001,
root 0x79a, subw 0x0, time 59337451, (648,900), root:(648,900),
state 0x0, keycode 38 (keysym 0x61, a), same_screen YES,
XLookupString gives 1 bytes: (61) "a"
XFilterEvent returns: False
이 키보드의 브랜드는 EOENKK입니다.
출력 bluetoothctl info <device>
:
[Bluetooth Keyboard]# info 15:10:40:4F:00:07
Device 15:10:40:4F:00:07 (public)
Name: Bluetooth Keyboard
Alias: Bluetooth Keyboard
Appearance: 0x03c1
Icon: input-keyboard
Paired: yes
Bonded: yes
Trusted: no
Blocked: no
Connected: yes
WakeAllowed: yes
LegacyPairing: no
UUID: Generic Access Profile (00001800-0000-1000-8000-00805f9b34fb)
UUID: Device Information (0000180a-0000-1000-8000-00805f9b34fb)
UUID: Human Interface Device (00001812-0000-1000-8000-00805f9b34fb)
UUID: Unknown (0000ff50-0000-1000-8000-00805f9b34fb)
Modalias: usb:v04E8p7021d0300
ManufacturerData Key: 0x4b51
ManufacturerData Value:
49 45 IE
[Bluetooth Keyboard]#