Using Xubuntu 19.10, I'm attempting to calibrate the touchscreen of a Toughbook CF-19 MK5. I've used xinput_calibrator as others have suggested which completes and gives me a snippet to copy into an xorg.conf file, but there's a problem:

chris@helmhorn:~$ sudo xinput_calibrator -v
Calibrating standard Xorg driver "Fujitsu Component USB Touch Panel Pen (0)"
        current calibration values: min_x=0, max_x=16777215 and min_y=0, max_y=16777215
        If these values are estimated wrong, either supply it manually with the --precalib option, or run the 'get_precalib.sh' script to automatically get it (through HAL).
DEBUG: Name 'Fujitsu Component USB Touch Panel Pen (0)' does not match any in '/sys/class/input/event*/device/name'
        --> Making the calibration permanent <--
  copy the snippet below into '/etc/X11/xorg.conf.d/99-calibration.conf' (/usr/share/X11/xorg.conf.d/ in some distro's)
Section "InputClass"
        Identifier      "calibration"
        MatchProduct    "!!Name_Of_TouchScreen!!"
        Option  "MinX"  "1267029"
        Option  "MaxX"  "16165546"
        Option  "MinY"  "615310"
        Option  "MaxY"  "14567195"
        Option  "SwapXY"        "0" # unless it was already set to 1
        Option  "InvertX"       "0"  # unless it was already set
        Option  "InvertY"       "0"  # unless it was already set

Change '!!Name_Of_TouchScreen!!' to your device's name in the config above.

The calibration doesn't get applied, and putting the snippet in /usr/share/X11/xorg.conf.d/99-calibration.conf alongside the other xorg files and rebooting has no effect. I suspect the error message about Name 'Fujitsu Component USB Touch Panel Pen (0)' does not match any in '/sys/class/input/event*/device/name' is the key, but there's not much information to find via Google.

Comparing the device names from the two pertinent sources:

chris@helmhorn:~$ cat /sys/class/input/event*/device/name | grep Fujitsu
Fujitsu Component USB Touch Panel
chris@helmhorn:~$ sudo xinput_calibrator --list
Device "Fujitsu Component USB Touch Panel Pen (0)" id=13

The device names don't match exactly, and putting either of those values in the xorg.conf.d file has no effect.

Edit: the best information I could find on Google was this site in Korean which I had to read with a translator; basically it recommends using a different matcher like MatchUSBID "28bd: 000c".

This is the clearest information I've found so far:

chris@helmhorn:~$ sudo xinput --list
⎡ Virtual core pointer                          id=2    [master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer                id=4    [slave  pointer  (2)]
⎜   ↳ PS/2 Generic Mouse                        id=11   [slave  pointer  (2)]
⎜   ↳ Fujitsu Component USB Touch Panel Pen (0) id=13   [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=8    [slave  keyboard (3)]
    ↳ Fujitsu Component USB Touch Panel         id=9    [slave  keyboard (3)]
    ↳ AT Translated Set 2 keyboard              id=10   [slave  keyboard (3)]
    ↳ Panasonic Laptop Support                  id=12   [slave  keyboard (3)]
chris@helmhorn:~$ sudo xinput_calibrator --list
Device "Fujitsu Component USB Touch Panel Pen (0)" id=13

It still doesn't tell me yet what's wrong, but it shows the touch panel and the pen as separate devices, and calibrator is trying to work with the pen.

Edit: I found a recent blog post from someone with a very similar problem on the same hardware. After xorg.conf didn't work, they decided to create a script invoking xinput set-prop at login time. I'll see if their solution works for me. As a bonus, they talked about on-screen keyboards, which I'll also need.

1 Answer 1


Update: I revisited this and found this Ubuntu Forums post, which correctly recommended:

sudo apt install xserver-xorg-input-evdev
sudo apt remove xserver-xorg-input-libinput

After a reboot, xinput_calibrator is able to identify the touchscreen and correctly calibrate it!

Original answer:

This blog post was the best workaround I could find. Rather than put the configuration in xorg.conf files, this solution invokes xinput set-prop in a script, which is then called at login time. This bypasses the need to figure out a nice way to tell xorg.conf which device we're talking about. It's not pretty, but it works.


# Coordinate touch panel to screen

xinput set-prop "Fujitsu Component USB Touch Panel" --type=float "Coordinate Transformation Matrix" 1.115 0 -0.073 0 1.14 -0.04 0 0 1

As discussed in the blog post, the best way to tune the matrix parameters seems to be trial and error. The values from the blog post were a reasonably close starting point for me.

I'd still love to hear a solution that instead uses xorg.conf and makes xinput_calibrator happy, as that would make it much easier to tune.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.