自動反復は機能しません

自動反復は機能しません

私のラップトップでは、自動繰り返し()をオンにしてもxset r on機能しません。出力を見てみると、xev自動繰り返しが失敗する理由は、他のキーを間欠的に押して(何も押さなくても)、現在押しているキーの自動繰り返しがキャンセルされるためだと思われます。いずれかのキーを押さないと、次のイベントが繰り返し記録されます。

KeyPress event, serial 33, synthetic NO, window 0x1200001,
    root 0x123, subw 0x0, time 1652400, (-509,794), root:(455,814),
    state 0x0, keycode 221 (keysym 0x0, NoSymbol), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyRelease event, serial 33, synthetic NO, window 0x1200001,
    root 0x123, subw 0x0, time 1652400, (-509,794), root:(455,814),
    state 0x0, keycode 221 (keysym 0x0, NoSymbol), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False

実際には押さなかったにもかかわらず、キーコード221のキーが押されたように見えます。

もしそうなら、xorgがそのキーコードからキー入力をまったく受け取らないように、キーコードを完全に無効にすることは可能ですか?または、他のキーが押されたかどうかにかかわらず、キーを押し続けると自動的に繰り返すことができますか?


修正する:

実行後にsudo evtest隠された出力が次のようになります。

/dev/input/event11 PEAQ WMI hotkeys

何も押さないと、他の入力デバイスはイベントを送信しないようです。 evtestでキーボードイベントを確認すると、自動反復が機能します。


xevボタンを押さなかったときに数秒間実行されるフル出力:

Outer window is 0x1200001, inner window is 0x1200002

PropertyNotify event, serial 8, synthetic NO, window 0x1200001,
    atom 0x27 (WM_NAME), time 1651733, state PropertyNewValue

PropertyNotify event, serial 9, synthetic NO, window 0x1200001,
    atom 0x22 (WM_COMMAND), time 1651733, state PropertyNewValue

PropertyNotify event, serial 10, synthetic NO, window 0x1200001,
    atom 0x28 (WM_NORMAL_HINTS), time 1651733, state PropertyNewValue

CreateNotify event, serial 11, synthetic NO, window 0x1200001,
    parent 0x1200001, window 0x1200002, (10,10), width 50, height 50
border_width 4, override NO

PropertyNotify event, serial 14, synthetic NO, window 0x1200001,
    atom 0x15c (WM_PROTOCOLS), time 1651734, state PropertyNewValue

MapNotify event, serial 15, synthetic NO, window 0x1200001,
    event 0x1200001, window 0x1200002, override NO

ReparentNotify event, serial 28, synthetic NO, window 0x1200001,
    event 0x1200001, window 0x1200001, parent 0x4000d5,
    (0,0), override NO

ConfigureNotify event, serial 28, synthetic NO, window 0x1200001,
    event 0x1200001, window 0x1200001, (2,0), width 952, height 1033,
    border_width 2, above 0x0, override NO

PropertyNotify event, serial 28, synthetic NO, window 0x1200001,
    atom 0x15e (WM_STATE), time 1651735, state PropertyNewValue

MapNotify event, serial 28, synthetic NO, window 0x1200001,
    event 0x1200001, window 0x1200001, override NO

VisibilityNotify event, serial 28, synthetic NO, window 0x1200001,
    state VisibilityUnobscured

Expose event, serial 28, synthetic NO, window 0x1200001,
    (0,0), width 952, height 10, count 3

Expose event, serial 28, synthetic NO, window 0x1200001,
    (0,10), width 10, height 58, count 2

Expose event, serial 28, synthetic NO, window 0x1200001,
    (68,10), width 884, height 58, count 1

Expose event, serial 28, synthetic NO, window 0x1200001,
    (0,68), width 952, height 965, count 0

ConfigureNotify event, serial 28, synthetic YES, window 0x1200001,
    event 0x1200001, window 0x1200001, (962,18), width 952, height 1033,
    border_width 2, above 0x0, override NO

FocusIn event, serial 28, synthetic NO, window 0x1200001,
    mode NotifyNormal, detail NotifyNonlinear

KeymapNotify event, serial 28, synthetic NO, window 0x0,
    keys:  4294967236 0   0   0   16  0   0   0   0   0   0   0   0   0   0   0   
           0   0   0   0   0   0   0   0   0   0   0   0   0   0   0   0   

PropertyNotify event, serial 28, synthetic NO, window 0x1200001,
    atom 0x14f (_NET_WM_DESKTOP), time 1651736, state PropertyNewValue

KeyRelease event, serial 30, synthetic NO, window 0x1200001,
    root 0x123, subw 0x0, time 1651775, (-509,794), root:(455,814),
    state 0x0, keycode 36 (keysym 0xff0d, Return), same_screen YES,
    XLookupString gives 1 bytes: (0d) "
"
    XFilterEvent returns: False

MappingNotify event, serial 33, synthetic NO, window 0x0,
    request MappingKeyboard, first_keycode 8, count 248

KeyPress event, serial 33, synthetic NO, window 0x1200001,
    root 0x123, subw 0x0, time 1652400, (-509,794), root:(455,814),
    state 0x0, keycode 221 (keysym 0x0, NoSymbol), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyRelease event, serial 33, synthetic NO, window 0x1200001,
    root 0x123, subw 0x0, time 1652400, (-509,794), root:(455,814),
    state 0x0, keycode 221 (keysym 0x0, NoSymbol), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyPress event, serial 34, synthetic NO, window 0x1200001,
    root 0x123, subw 0x0, time 1653200, (-509,794), root:(455,814),
    state 0x0, keycode 221 (keysym 0x0, NoSymbol), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyRelease event, serial 34, synthetic NO, window 0x1200001,
    root 0x123, subw 0x0, time 1653200, (-509,794), root:(455,814),
    state 0x0, keycode 221 (keysym 0x0, NoSymbol), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyPress event, serial 34, synthetic NO, window 0x1200001,
    root 0x123, subw 0x0, time 1654000, (-509,794), root:(455,814),
    state 0x0, keycode 221 (keysym 0x0, NoSymbol), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyRelease event, serial 34, synthetic NO, window 0x1200001,
    root 0x123, subw 0x0, time 1654000, (-509,794), root:(455,814),
    state 0x0, keycode 221 (keysym 0x0, NoSymbol), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False

MappingNotify event, serial 34, synthetic NO, window 0x0,
    request MappingKeyboard, first_keycode 8, count 248

KeyPress event, serial 34, synthetic NO, window 0x1200001,
    root 0x123, subw 0x0, time 1654760, (-509,794), root:(455,814),
    state 0x0, keycode 133 (keysym 0xffeb, Super_L), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

MappingNotify event, serial 35, synthetic NO, window 0x0,
    request MappingKeyboard, first_keycode 8, count 248

KeyPress event, serial 35, synthetic NO, window 0x1200001,
    root 0x123, subw 0x0, time 1654800, (-509,794), root:(455,814),
    state 0x40, keycode 221 (keysym 0x0, NoSymbol), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyRelease event, serial 35, synthetic NO, window 0x1200001,
    root 0x123, subw 0x0, time 1654800, (-509,794), root:(455,814),
    state 0x40, keycode 221 (keysym 0x0, NoSymbol), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False

MappingNotify event, serial 36, synthetic NO, window 0x0,
    request MappingKeyboard, first_keycode 8, count 248

FocusOut event, serial 36, synthetic NO, window 0x1200001,
    mode NotifyGrab, detail NotifyAncestor

ClientMessage event, serial 37, synthetic YES, window 0x1200001,
    message_type 0x15c (WM_PROTOCOLS), format 32, message 0x15d (WM_DELETE_WINDOW)

ベストアンサー1

カーネル4.13で導入されたバグのようです。Redhat bugzilla のバグ #1497861

peaq_wmiモジュールを取り外すことも解決策であることがわかりました。誰かがこの問題を解決するためにパッチを提出したようです。

peaq_wmi(モジュールを削除するにはコマンドを実行できますsudo modprobe -r peaq_wmi。)

おすすめ記事