More on the X61 Tablet: Calibrating the touchscreen

I’ve updated my tablet script for Ubuntu 10.04 to fix the calibration of the multitouch touchscreen on my X61 tablet.  (Oddly, the stylus and the finger touch seem to be completely different devices with their own calibration).  Here it is:

#!/bin/bash
# Remap the side button to bring up context menu.
xsetwacom set "Serial Wacom Tablet" Button1 "button 1"
xsetwacom set "Serial Wacom Tablet" Button2 "button 3"
# Fix the "Serial Wacom Tablet eraser" button to paste
xsetwacom set "Serial Wacom Tablet eraser" Button1 "button 2"
# Calibrate the touchscreen on multitouch X61
xsetwacom --set 'Serial Wacom Tablet touch' 'TopX' '40'
xsetwacom --set 'Serial Wacom Tablet touch' 'TopY' '86'
xsetwacom --set 'Serial Wacom Tablet touch' 'BottomX' '940'
xsetwacom --set 'Serial Wacom Tablet touch' 'BottomY' '948'
# Done

I run this script as a task when my Gnome session starts (System/Preferences/Startup Applications) and I added it to the beginning of /etc/gdm/Init/Default so that I could use the touchscreen to log in.  Since the Gnome on-screen keyboard for the login screen is too small for finger touch, I also edited /usr/share/gdm/autostart/LoginWindow/onboard.desktop to make the onscreen keyboard bigger:

Exec=onboard --size 1022x190 -x 0 -y 0

Now I can log in without the stylus!

You can get the numbers for touchscreen calibration by running:

xinput test 'Serial Wacom Tablet touch'

I did have to tweak the numbers that xinput spit out to get the best overall touchscreen response – just putting the numbers xinput showed for TopX and BottomX resulted in touch being a bit off on the right hand side of the screen.

Source: http://www.ormiret.com/?q=node/26

Tags: , , ,

Comments are closed.