I'm so tired of the touchpad that I need to beat...
When using a notebook, you often accidentally touch the touch screen, which causes the cursor to run around.
Method 1:
Very simple, just type sudo modprobe -r psmouse
If you want to open it, just remove - r.
Of course, you can also write a file with the bash you learned recently, and then switch the touch screen on and off interactively every time.
You can do not write with vim ~/psmouse, just write the following code in psmouse (you can copy and paste directly, of course), save and exit, and then run directly. / psmouse.
Code:
echo "" echo "" read -p "Turn the touchpad on or off?(open/Close)(y/n): " yn if [ "$yn" = "y" ] || [ "$yn" = "Y" ] then sudo modprobe psmouse echo "Touch pad is on" echo "" echo "" elif [ "$yn" = "n" ] || [ "$yn" = "N" ] then sudo modprobe -r psmouse echo "Touch pad is off" echo "" echo "" fi
Method two:
View nearly enabled devices: xinput list
jack@jack-W65KJ1-KK1:~ $ xinput list ⎡ Virtual core pointer id=2 [master pointer (3)] ⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)] ⎜ ↳ PixArt Gaming Mouse Consumer Control id=12 [slave pointer (2)] ⎜ ↳ PixArt Gaming Mouse id=16 [slave pointer (2)] ⎜ ↳ SynPS/2 Synaptics TouchPad id=17 [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=9 [slave keyboard (3)] ↳ Sleep Button id=10 [slave keyboard (3)] ↳ AT Translated Set 2 keyboard id=15 [slave keyboard (3)] ↳ BisonCam,NB Pro: BisonCam,NB Pr id=14 [slave keyboard (3)] ↳ Video Bus id=8 [slave keyboard (3)] ↳ PixArt Gaming Mouse Keyboard id=11 [slave keyboard (3)] ↳ PixArt Gaming Mouse Consumer Control id=13 [slave keyboard (3)]
Dazzled, right? You pull out your mouse and try:
jack@jack-W65KJ1-KK1:~ $ xinput list ⎡ Virtual core pointer id=2 [master pointer (3)] ⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)] ⎜ ↳ SynPS/2 Synaptics TouchPad id=17 [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=9 [slave keyboard (3)] ↳ Sleep Button id=10 [slave keyboard (3)] ↳ AT Translated Set 2 keyboard id=15 [slave keyboard (3)] ↳ BisonCam,NB Pro: BisonCam,NB Pr id=14 [slave keyboard (3)] ↳ Video Bus id=8 [slave keyboard (3)]
A few are missing...
As we all know, touchpad is the line:
⎜ ↳ SynPS/2 Synaptics TouchPad id=17 [slave pointer (2)]
You can type xinput -h for usage
Use xinput disable 17 to disable the touchpad
Use xinput enable 17 to turn on the touchpad
That is: XInput disable / enable < device > (here is the ID of the device)