Linux配置输入设备(如停用笔记本键盘)

config devices on Linux use xinput

install

#Manjaro
sudo pacman -S xorg-xinput

use

  1. list all the input devices

    xinput list
    

    output:

    [jarvis@jarvis-pc ~]$ xinput list
    ⎡ Virtual core pointer                       id=2    [master pointer  (3)]
    ⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
    ⎜ ↳ ETPS/2 Elantech Touchpad id=15 [slave pointer (2)]
    ⎣ Virtual core keyboard id=3 [master keyboard (2)]
    ↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
    ↳ Power Button id=6 [slave keyboard (3)]
    ↳ Video Bus id=7 [slave keyboard (3)]
    ↳ Power Button id=8 [slave keyboard (3)]
    ↳ Heng Yu Technology Poker id=9 [slave keyboard (3)]
    ↳ Heng Yu Technology Poker Consumer Control id=10 [slave keyboard (3)]
    ↳ Heng Yu Technology Poker System Control id=11 [slave keyboard (3)]
    ↳ Lenovo EasyCamera: Lenovo EasyC id=12 [slave keyboard (3)]
    ↳ Ideapad extra buttons id=13 [slave keyboard (3)]
    ↳ AT Translated Set 2 keyboard id=14 [slave keyboard (3)]
  2. find the devices [id]

  3. config

    #list properties that can be set for the given devices
    xinput list-props [id]
    #disable
    xinput set-prop [id] 'Device Enabled' 0
    #enable
    xinput set-prop [id] 'Device Enabled' 1

reference

  1. xinput

转载于:https://www.cnblogs.com/QQ-1615160629/p/configdevicesonLinux.html

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值