Unable to get Wacom events from /dev/input/event*

2k views Asked by At

I have created a pygtk program to monitor the keyboard status and mouse clicks across any application (i.e. not just for my application). This uses evdev by Micah Dowty which basically monitors /dev/input/event* for output and decodes the information in a way that I can display the information to the user.

The program works perfectly for USB keyboards and mice, but doesn't work for a USB Wacom (nor serial Wacom), even when running as root. I don't get any events for coming out of any of the /dev/input/* nodes for the Wacom as use it. It's not just my Wacom, but also they guys from the podcast "Meet the Gimp" (Rolf and Philippe) don't get anything as well.

The code lives at http://code.google.com/p/key-mon.

To test, you can run something like:

sudo ./evdev.py /dev/input/event0 

You should see events coming out for whatever is connected to event0 as you move the mouse or click the keyboard, for example.

1

There are 1 answers

0
tito On

This is due to X that take the full control of your input device, you can't read event yourself. You might have one of theses 2 issues :

  1. A "catchall" is actually getting your device. In your /var/log/Xorg.0.log, you should see a line like :

    Stantum MTP USB Controller: Applying InputClass "evdev touchscreen catchall"

    But for wacom of course. If it's true, you can disable the "touchscreen" catchall by editing your /usr/share/X11/xorg.conf.d/10-evdev.conf, and remove the section that talking about touchscreen.

  2. Maybe you'll fit in the Wacom section, so edit the /usr/share/X11/xorg.conf.d/50-wacom.conf, and remove appropriate section that can match your device.

Of course, both of the issue is not resolved in a clean manner, and you can't have X and Kernel event working at the same time. (I never found a solution with Wacom, if anybody have, please share !)