ubuntu-wacom-tablet-hotplugging

Update 11-04-2008: The release version of Ubuntu 8.10 Intrepid should work out of the box, so you don’t need to do any of this. However, only the stylus works. If linuxwacom comes out with an update to use the eraser and tablet buttons, you might need to manually install the linuxwacom driver, but right now, enjoy the “it just works” philosophy. :)

Ubuntu 8.10 “Intrepid Ibis” will use Xorg 7.4’s input hotplugging, allowing auto-detection of input devices (e.g. keyboards, mice, tablets) during an X session. (Previously, input devices were only detected at the startup of an X session.)

Note that there are still a number of bugs with hotplugging:

  • you must install the latest linuxwacom driver to get correct clicking
  • hotplugging will only recognize the stylus events (so no eraser or express buttons)
  • unplugging the tablet causes X to crash. Edit 9-20-08: There is a line in the linuxwacom source you need to edit to fix this (see step 4 of Manual Installation below). [linuxwacom post] Edit 11-04-08: Intrepid updated the linuxwacom driver that ships with Intrepid, so you don’t need to install the updated linuxwacom driver.

Installing LinuxWacom driver in Intrepid
(based off the Hardy linuxwacom install thread, here. Tested on Intrepid alpha 6 LiveCD)

Easy Method:

  1. Download my install_linuxwacom script
  2. Run the script
    chmod +x install_linuxwacom
    ./install_linuxwacom
  3. Enjoy!

Manual Installation Steps:

  1. Install required packages
    sudo apt-get update
    sudo apt-get install linux-headers-$(uname -r) build-essential x11proto-core-dev libxau-dev libxdmcp-dev x11proto-input-dev x11proto-kb-dev xtrans-dev libx11-dev x11proto-xext-dev libxext-dev libxi-dev linux-libc-dev libc6-dev libncurses5-dev xserver-xorg-dev tk-dev tcl-dev -y
  2. Download latest linuxwacom-dev package from linuxwacom (0.8.1-4 as of this writing)
    wget -nd http://prdownloads.sourceforge.net/linuxwacom/
    linuxwacom-0.8.1-4.tar.bz2
  3. Extract the source
    tar xjvf linuxwacom-0.8.1-4.tar.bz2
    cd linuxwacom-0.8.1-4
  4. To fix the X crashing when unplugging the tablet, edit line 381 of src/xdrv/wcmConfig.c replacing WCM_UNINIT_CALLED with WCM_XORG_XSERVER_1_4
    sed -i -e '381s/WCM_UNINIT_CALLED/WCM_XORG_XSERVER_1_4/' src/xdrv/wcmConfig.c
  5. Compile the driver
    ./configure --enable-wacom
    make
    sudo make install
  6. (Optional) You can test the kernel module before installing it. Plug in your tablet and see if it works correctly after executing these commands.
    sudo rmmod wacom
    sudo insmod src/2.6.26/wacom.ko

    If it doesn’t work, you can reload the original driver. (Or just reboot your computer)

    sudo rmmod wacom
    sudo modprobe wacom
  7. Install the kernel module (and backup the original). (Note: The 2.6.26 module works with Intrepid’s 2.6.27 kernel)
    cp /lib/modules/$(uname -r)/kernel/drivers/input/tablet/wacom.ko wacom.ko.$(uname -r)
    sudo cp src/2.6.26/wacom.ko /lib/modules/$(uname -r)/kernel/drivers/input/tablet/wacom.ko
  8. Reload the kernel module with the new version
    sudo rmmod wacom
    sudo modprobe wacom
  9. Enjoy!

Read the rest of this entry »