Created attachment 1236716 [details]
Tablet Calibration Script
Description of problem:
Various properties available under evdev are not available under libinput
Steps to Reproduce:
1. Attempt to calibrate tablet using the attached shell script
2. Error: neither property is available
3. Remove the tablet catchall(s) from 60-libinput.conf
4. Restart X
5. Calibration script now runs
Error occurs stating that various properties are not available
Equivalent properties be available to calibrate tablet
It would be nice if this tablet (HUION 580) would show up in the wacom settings tool. I feel like the way I have to calibrate this tablet is very clunky at best. My goal with the attached script is to swap the axes so that I can use the tablet without a USB cable extender since the cable connects on the left side of the tablet and my computer is on the right side of my desk.
I also want the tablet to be locked to a single screen instead of mapping to my whole desktop. The tablet's sensitivity range is 0-32000 on X and 0-20000 on Y. To lock this to my left monitor, I would normally have to map the X range as 0-64000 so that the "usable" range only reaches the end of my left screen. However, since the axes are inverted, 0 is on the right side, not the left, so I need to map from -32000-32000 so that 32000-0 are my left screen and -1--32000 are the right (unusable range)
To say the least, this sort of manual mapping is a main. I had to do some very unpleasant math when one of my screens was flipped horizontally and wasn't perfectly centred with with other. The Windows driver provided by HUION has some simple options that let you select which screen to map to, which axes to invert, etc. I'm unsure how the GNOME wacom settings tool is supposed to work since it doe snot detect my tablet, but I'd really like some usability improvements in this area someday.
what's the sudo evemu-describe output for this device?
the calibration script is specific to the evdev driver, those properties don't exist in the libinput driver but there is a "libinput Calibration Matrix" property that more-or-less does the same thing. The only exception is that the values are proportional to the width/height of the device, i.e. the value 1.0 refers to "total with". So you can adjust your script accordingly.
(In reply to lmanning17 from comment #0)
> I also want the tablet to be locked to a single screen instead of mapping to
> my whole desktop.
This is usually done by setting the driver-independent Coordinate Transformation Matrix, see e.g. https://wiki.archlinux.org/index.php/Calibrating_Touchscreen
> I'm unsure how the GNOME wacom settings tool is
> supposed to work since it doe snot detect my tablet, but I'd really like
> some usability improvements in this area someday.
I'll check what's happening but since we already do all this for wacom tablets, it shouldn't be too hard to fix.