Install inputplug by entering the following commands in the terminal:
sudo apt update sudo apt install inputplug
Description:
XInput monitor
inputplug is a daemon which connects to a running X server and monitors its XInput hierarchy change events, such as an input device being attached or removed, enabled or disable etc, and runs some command when these events happen.
Homepage: http://bitbucket.org/andrew_shadura/inputplug
Version: 0.3~hg20150512-1build1
Section: universe/x11