04/03/2008

How to run a Wacom tablet on Nvidia or ATI AIGLX

Never, never, never, never ... use the Sax2-Module (tantalisingly dangled in front of your nose in YaST) to add a tablet, if you value your hand-written xorg.conf. Or back it up first.

I finally got my Wacom Graphire4 tablet working with nVidia AIGLX. (note that graphics tablets are generally not supported on XGL!) The problems I experienced in setting this up were:
  • getting the right identifier in /dev/input (the by-id one worked fine)
  • wacdump segfaulting with sudo - had to use a real root shell
  • GIMP Window mode resulting in nasty stylus-cursor offset, chose the Screen setting instead

HOWTO: Connect your tablet before booting (precautionarily). Make sure the x11-input-wacom and x11-input-wacom-tools packages are installed, they should be part of the SuSE default package selection anyway. Get the tablet event-mouse identifier from /dev/input/by-id (ls output shown below).
avocadohead@tisiphone:~> ls /dev/input/by-id
usb-Logitech_USB-PS.2_Optical_Mouse-event-mouse usb-WACOM_CTE-640-U_V4.0-3-event-mouse
usb-Logitech_USB-PS.2_Optical_Mouse-mouse usb-WACOM_CTE-640-U_V4.0-3-mouse

Edit /etc/X11/xorg.conf:
Section "InputDevice"
Driver "wacom"
Identifier "stylus"
Option "Device" "/dev/input/by-id/usb-WACOM_CTE-640-U_V4.0-3-event-mouse"
Option "Type" "stylus"
Option "USB" "on"
EndSection

Section "InputDevice"
Driver "wacom"
Identifier "eraser"
Option "Device" "/dev/input/by-id/usb-WACOM_CTE-640-U_V4.0-3-event-mouse"
Option "Type" "eraser"
Option "USB" "on"
EndSection

Section "InputDevice"
Driver "wacom"
Identifier "cursor"
Option "Device" "/dev/input/by-id/usb-WACOM_CTE-640-U_V4.0-3-event-mouse"
Option "Type" "cursor"
Option "Mode" "relative"
Option "USB" "on"
EndSection

Section "InputDevice"
Driver "wacom"
Identifier "pad"
Option "ButtonsOnly" "on"
Option "Button9" "2" #oder 1
Option "Button13" "3"
Option "Device" "/dev/input/by-id/usb-WACOM_CTE-640-U_V4.0-3-event-mouse"
Option "Type" "pad"
Option "USB" "on"
EndSection


Section "ServerLayout"
Identifier "Layout[all]"
InputDevice "Keyboard[0]" "CoreKeyboard"
InputDevice "Mouse[1]" "CorePointer"
InputDevice "Mouse[3]" "SendCoreEvents"
InputDevice "stylus" "SendCoreEvents"
InputDevice "eraser" "SendCoreEvents"
InputDevice "cursor" "SendCoreEvents"
InputDevice "pad" "SendCoreEvents"

Option "Clone" "off"
Option "Xinerama" "off"
Screen "Screen[0]"
EndSection

Restart X or reboot. Test the tablet with wacdump:
tisiphone:/home/avocadohead # wacdump /dev/input/by-id/usb-WACOM_CTE-640-U_V4.0-3-event-mouse
Just move the stylus and watch the console output.

GIMP configuration: File->Preferences->Input devices->Configure Extended Input Devices. For "Mode", set everything to "Screen".

This is just how things worked on my machine with a Graphire USB non-LCD tablet. For different devices, adapt the Ubuntu HOWTO accordingly.

Button support worked well, even the scroll wheel (some people reported inverted scrolling). It' s not exactly plug and play, however; I had to restart X after plugging in to get it properly working.

For older SuSE distros, one had to compile the driver and kernel modules from scratch. Although the present SuSE packages seem to be sufficient FAPP, you can get additional tweaking tips and a lot of background information on the Linuxwacom HOWTO.

Applied the same procedure to Xanthippe (openSuSE 10.3 64bit, ATI Radeon X1300), worked OK.

No comments: