Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disable laptop's touchpad and keyboard by xinput #48

Open
ysl2 opened this issue Mar 17, 2024 · 0 comments
Open

Disable laptop's touchpad and keyboard by xinput #48

ysl2 opened this issue Mar 17, 2024 · 0 comments

Comments

@ysl2
Copy link
Owner

ysl2 commented Mar 17, 2024

Ref: https://bbs.archlinuxcn.org/viewtopic.php?id=10561

  1. First, we need to find the touchpad and keyboard's id.
❯ xinput list
⎡ Virtual core pointer                    	id=2	[master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer              	id=4	[slave  pointer  (2)]
⎜   ↳ OBINS OBINS
AnnePro2 Mouse              	id=13	[slave  pointer  (2)]
⎜   ↳ YICHIP Wireless Device Mouse            	id=14	[slave  pointer  (2)]
⎜   ↳ YICHIP Wireless Device Consumer Control 	id=16	[slave  pointer  (2)]
⎜   ↳ SYNA3073:00 06CB:8265 Mouse             	id=17	[slave  pointer  (2)]
⎜   ↳ SYNA3073:00 06CB:8265 Touchpad          	id=18	[slave  pointer  (2)]
⎜   ↳ SynPS/2 Synaptics TouchPad              	id=20	[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)]
    ↳ Video Bus                               	id=8	[slave  keyboard (3)]
    ↳ Sleep Button                            	id=9	[slave  keyboard (3)]
    ↳ OBINS OBINS
AnnePro2                    	id=10	[slave  keyboard (3)]
    ↳ OBINS OBINS
AnnePro2 Consumer Control   	id=11	[slave  keyboard (3)]
    ↳ OBINS OBINS
AnnePro2 Keyboard           	id=12	[slave  keyboard (3)]
    ↳ YICHIP Wireless Device System Control   	id=15	[slave  keyboard (3)]
    ↳ AT Translated Set 2 keyboard            	id=19	[slave  keyboard (3)]
    ↳ HP WMI hotkeys                          	id=21	[slave  keyboard (3)]
    ↳ YICHIP Wireless Device Consumer Control 	id=22	[slave  keyboard (3)]

In the command output above, the SYNA3073:00 06CB:8265 Touchpad id=18 is the touchpad, and the AT Translated Set 2 keyboard id=19 is the keyboard.

  1. Then, we use the command below to disable:
# Disable the touchpad
xinput disable 18
# Disable the keyboard
xinput disable 19
  1. If we want to re-enable, just use xinput enable {id}.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant