Search This Blog

Thursday, November 22, 2018

How to disable device on Fedora

You can "grab" input from the unwanted device using evtest so that they are not delivered to other processes. 


To list all event devices:
$ sudo evtest
No device specified, trying to scan all of /dev/input/event*
Available devices:
/dev/input/event0: Lid Switch
/dev/input/event1: Power Button
/dev/input/event2: Sleep Button
/dev/input/event3: Power Button
/dev/input/event4: AT Translated Set 2 keyboard
/dev/input/event5: Logitech USB Receiver
/dev/input/event6: Logitech USB Receiver
/dev/input/event7: DLLC6AE:00 06CB:75BF Touchpad
/dev/input/event8: Video Bus
/dev/input/event9: PS/2 Synaptics TouchPad
/dev/input/event10: DELL Wireless hotkeys
/dev/input/event11: HDA Intel PCH Headphone Mic
/dev/input/event12: Dell WMI hotkeys
/dev/input/event13: HDA Intel HDMI HDMI/DP,pcm=3
/dev/input/event14: HDA Intel HDMI HDMI/DP,pcm=7
/dev/input/event15: HDA Intel HDMI HDMI/DP,pcm=8
/dev/input/event16: HDA Intel HDMI HDMI/DP,pcm=9
/dev/input/event17: HDA Intel HDMI HDMI/DP,pcm=10
/dev/input/event18: Integrated_Webcam_HD: Integrate
Select the device event number [0-18]: 

To grab the input from the keyboard:
$ sudo evtest --grab /dev/input/event4