Re-Enabling touchpad with xinput -enable 13 fails

RigasW

New Member
Joined
Jun 20, 2019
Messages
5
Reaction score
1
Credits
0
Dear all,

on my MINT 19.1 notebook I can successfully disable the touchpad using

xinput disable 13.

When I try to enable the touchpad again with

xinput enable 13

it does not work (I do not get any error message on that).

When doing disabling and enabling with my "admin" user, it works.
But the regular "desktop" user can only disable the touchpad, but not re-enable it.

this is how my xinput looks:

xinput
⎡ Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ USB OPTICAL MOUSE id=10 [slave pointer (2)]
⎜ ↳ SynPS/2 Synaptics TouchPad id=13 [slave pointer (2)]
⎜ ↳ Sony Vaio Jogdial id=8 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
↳ Video Bus id=6 [slave keyboard (3)]
↳ Sony Vaio Keys id=7 [slave keyboard (3)]
↳ Power Button id=9 [slave keyboard (3)]
↳ USB2.0 Camera: USB2.0 Camera id=11 [slave keyboard (3)]
↳ AT Translated Set 2 keyboard id=12 [slave keyboard (3)]



Did I miss something?

Thanks in advance,

RigasW
 


After testing for several hours I found, that disabling the touchpad with "xinput disable nn" seems to work pretty consistent, while the following enabling only sometimes worked (as then as admin user) but in most of the test cases did not work at all.

To be precise, I could not move the cursor with the touchpad after doing a "enable".

The touchpad still responded to pressure, so I could do a left and a right mouse click with it (which is pretty useless, if you cannot move the cursor to where you want to click ....)
 
I could solve the issue:

For a reason I do not remember I had installed the package "Xserver-xorg-input-synapics" when I set up the notebook.

I removed it ... and now everything works as designed.

xinput disable 12: Disables the touchpad
xinput enable 12: Enables it again.

I connected the functions to F2 and Shift-F2.

RigasW
 
G'day @RigasW and welcome to linux.org :)

Sorry I missed seeing this one but you seem to have a working solution in place, yeah?

If the touchpad is now on ID 12, did the AT keyboard move elsewhere?

If you want, give us the xinput output again and we'll look.

For a reason I do not remember I had installed the package "Xserver-xorg-input-synapics" when I set up the notebook.

... Possibly because your touchpad is Synaptics, but if it works without that all the better.


Sometimes when we use xinput to change the status of a device, and then other events occur, the device IDs can get re-mapped slightly.

With your previous xinput setup, an alternative to

Code:
xinput disable 13

# alternative is

xinput disable "SynPS/2 Synaptics TouchPad"

If, then, you come back to xinput later and your device ID is no longer there or has been re-mapped, you can scroll back through your bash history (direction key), find the exact syntax, and substitute enable for disable. This will then assign a new ID.

If you want to save your xinput output for future reference, it can be as easy as

Code:
xinput > xinput-list-save

# or choose your own filename, just not the command "xinput"

It will then be available in your home folder/partition.

Hope this helps

Chris Turner
wizardfromoz
 
Hi Chris,

that is how it looks like now:

⎡ Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ SynPS/2 Synaptics TouchPad id=12 [slave pointer (2)]
⎜ ↳ Sony Vaio Jogdial id=8 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
↳ Video Bus id=6 [slave keyboard (3)]
↳ Sony Vaio Keys id=7 [slave keyboard (3)]
↳ Power Button id=9 [slave keyboard (3)]
↳ USB2.0 Camera: USB2.0 Camera id=10 [slave keyboard (3)]
↳ AT Translated Set 2 keyboard id=11 [slave keyboard (3)]

At the moment it works as I want it to work:

Touchpad is disabled, no cursor is jumping around the screen and I am not overwriting and deleting text that I have written seconds before.

If I understand correctly, you would advise that I use the device name instead of the device id for my disable/enable shortcuts?

Greetings from sunny Munich,

RigasW
 
Munchen, eh? We have a young fellow named Peer you'll meet, from Hamburg :)

If I understand correctly, you would advise that I use the device name instead of the device id for my disable/enable shortcuts?

I would, in the longer term, in case the IDs change.

But if, in the short term, then obviously it is quicker to type

Code:
xinput disable 12

You will likely be aware that the xinput disable command only lasts for the duration of the session you are in - when you reboot, the functionality is lost and you have to invoke it again.

Touchpad is disabled, no cursor is jumping around the screen and I am not overwriting and deleting text that I have written seconds before.

There are longer-term solutions readily available, and I can tell you about them - where to find the config files and how to make the changes.

There are usually, also, options to disable the touchpad while typing, you may be interested in that?

Just let us know what Linux Distribution you are using - name, version and DE (Desktop Environment) eg MATE, Cinnamon &c, and we can go from there.

Cheers

Wizard
 
Hi,

thanks for your great support!

I am running Mint 19.1 xfce.

I tried a configuration of the touchpad where it was automatically disabled when you press a key on the keyboard ... most of the time that worked, but not always, and then it was really a pain. I can type pretty fast with 10 fingers and more than once it happened that I unwillingly highlighted a big junk of text and deleted it by overwriting.

The solution where I can disable / enable the touchpad with a shortcut (I assigned it to F2 / Shift-F2)
fits perfect for my needs ... as long as this is a stable, reliable behavior.

Cheers,

RigasW
 
Hi All,

I'm having a similar problem, though on a slightly different system. I am running Xubuntu 22.04 (so xfce)

This works like a charm to disable the trackpad:

Bash:
xinput disable "DELL0A66:00 0488:101A Touchpad"

but when I try to use this to re-enable the trackpad:

Bash:
xinput enable "DELL0A66:00 0488:101A Touchpad"

The pressure sensor (e.g. right/left click) work just fine, but I am unable to move the cursor. This persists for the full session (e.g. until I reboot). And enabling/disabling the trackpad via the GUI instance makes no difference. To be clear if I have not disabled the device via the terminal the GUI instance works perfectly.

Note I have tried this as a sudo user and as a normal user, no change and I do not have Xserver-xorg-input-synapics installed.

Any more threads to pull on?

FYI my xinput -- list is as follows:

Code:
⎡ Virtual core pointer                        id=2    [master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer                  id=4    [slave  pointer  (2)]
⎜   ↳ DP-1                                        id=9    [slave  pointer  (2)]
⎜   ↳ PS/2 Generic Mouse                          id=23    [slave  pointer  (2)]
⎜   ↳ MX Vertical Mouse                           id=14    [slave  pointer  (2)]
⎜   ↳ DELL0A66:00 0488:101A Mouse                 id=16    [slave  pointer  (2)]
⎜   ↳ DELL0A66:00 0488:101A Touchpad              id=17    [slave  pointer  (2)]
⎣ Virtual core keyboard                       id=3    [master keyboard (2)]
    ↳ Virtual core XTEST keyboard                 id=5    [slave  keyboard (3)]
    ↳ Video Bus                                   id=6    [slave  keyboard (3)]
    ↳ Power Button                                id=7    [slave  keyboard (3)]
    ↳ Sleep Button                                id=8    [slave  keyboard (3)]
    ↳ Integrated_Webcam_HD: Integrate             id=15    [slave  keyboard (3)]
    ↳ Intel HID events                            id=18    [slave  keyboard (3)]
    ↳ Intel HID 5 button array                    id=19    [slave  keyboard (3)]
    ↳ Dell Privacy Driver                         id=20    [slave  keyboard (3)]
    ↳ Dell WMI hotkeys                            id=21    [slave  keyboard (3)]
    ↳ AT Translated Set 2 keyboard                id=22    [slave  keyboard (3)]
    ↳ DP-1                                        id=24    [slave  keyboard (3)]
    ↳ UVC Camera (046d:0825)                      id=13    [slave  keyboard (3)]
    ↳ HD 458BT (AVRCP)                            id=26    [slave  keyboard (3)]
    ↳ Dell KB216 Wired Keyboard System Control    id=10    [slave  keyboard (3)]
    ↳ Dell KB216 Wired Keyboard Consumer Control    id=11    [slave  keyboard (3)]
    ↳ Dell KB216 Wired Keyboard                   id=12    [slave  keyboard (3)]
 
Last edited:
G'day @MattD and welcome to linux.org :)

Just a note before I forget, with that stuff above below

FYI my xinput -- list is as follows:

Put that output, in future, inside code tags, as can be found below

dHWsUJl.png


  1. Is/was there a reason for disabling the trackpad, or were you just practising the commands?
  2. Do you have Timeshift installed, with a recent snapshot available? If No, can you expand on
  3. This persists for the full session (e.g. until I reboot).
    In that, when you reboot, is the movement with the trackpad problematic from the start of the desktop session and what about at the login screen?
  4. Do you have a file /usr/share/X11/xorg.conf.d/40-libinput.conf ?

See how you go with those to begin with, and Helpers please note this is not the OP but I have left @MattD 's Post here so we can easily refer to other material in the thread.

Cheers

Chris Turner
wizardfromoz
 
Hi @wizardfromoz,

Thanks for getting back to me and I've made your suggestions.

  1. Is/was there a reason for disabling the trackpad, or were you just practising the commands?

I often use my laptop with a mouse in which case I end up accidentally hitting the trackpad... which drives me crazy. I tend to turn it off, but the issue is that I often forget to turn it back on. that's a bummer as xfce's mouse and touchpad gui... needs a mouse.

  1. Do you have Timeshift installed, with a recent snapshot available? If No, can you expand on
  2. This persists for the full session (e.g. until I reboot).
    In that, when you reboot, is the movement with the trackpad problematic from the start of the desktop session and what about at the login screen?

I don't have timeshift installed. everything functions perfectly until I use the terminal to run the
Code:
xinput disable "DELL0A66:00 0488:101A Touchpad"
. Then my problems start ( I cannot re-enable the touchpad). If I restart the machine it goes back to the last default (e.g. touchpad working if I had enabled it in the gui or touchpad disabled if I had enabled it in the gui). The mouse and trackpad gui work perfectly again (e.g., I can enable/disable it).

Interestingly, I discovered that if I first run
Code:
 xinput enable "DELL0A66:00 0488:101A Touchpad"
. Then I can enable/disable the trackpad from the terminal (via xinput), but I cannot disable the trackpad from the GUI... Honestly that provides an end-run, but it sounds like some sort of conflict.

  1. Do you have a file /usr/share/X11/xorg.conf.d/40-libinput.conf ?

yep:

Code:
# Match on all types of devices but joysticks
#
# If you want to configure your devices, do not copy this file.
# Instead, use a config snippet that contains something like this:
#
# Section "InputClass"
#   Identifier "something or other"
#   MatchDriver "libinput"
#
#   MatchIsTouchpad "on"
#   ... other Match directives ...
#   Option "someoption" "value"
# EndSection
#
# This applies the option any libinput device also matched by the other
# directives. See the xorg.conf(5) man page for more info on
# matching devices.

Section "InputClass"
        Identifier "libinput pointer catchall"
        MatchIsPointer "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection

Section "InputClass"
        Identifier "libinput keyboard catchall"
        MatchIsKeyboard "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection

Section "InputClass"
        Identifier "libinput touchpad catchall"
        MatchIsTouchpad "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection

Section "InputClass"
        Identifier "libinput touchscreen catchall"
        MatchIsTouchscreen "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection

Section "InputClass"
        Identifier "libinput tablet catchall"
        MatchIsTablet "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection
 
OK Matt, thanks for those responses. :)

What I can tell you is that, if you wish to disable the trackpad and have that state persist over reboots, you can do the following:

  1. Go into /usr/share/X11/xorg.conf.d/40-libinput.conf and where the section is saying
  2. Code:
    Section "InputClass"
            Identifier "libinput touchpad catchall"
            MatchIsTouchpad "on"
            MatchDevicePath "/dev/input/event*"
            Driver "libinput"
    EndSection
  3. Comment that out, that is, preface each line with a # so it looks as follows
    Code:
    #Section "InputClass"
    #        Identifier "libinput touchpad catchall"
    #        MatchIsTouchpad "on"
    #        MatchDevicePath "/dev/input/event*"
    #        Driver "libinput"
    #EndSection
  4. Save and exit the file and reboot.

Your trackpad should now be switched off. You can reverse the process if you wish to enable it again.

What I can't tell you is whether that will cause any issue with the mouse and trackpad gui, because I have not used it.

Let us know how you go.

BTW should I be the one to tell you that Mint 19.1 went EOL (end of life) last June?

Cheers

Wizard
 

Members online


Top