Installing OpenSUSE 10.2 on a ThinkPad X41 Tablet

From ThinkWiki
Revision as of 03:26, 29 November 2006 by Loki (Talk | contribs)
Jump to: navigation, search

Success Chart

Item Working Notes
Installation Network Installation Not Tested
USB Installation Yes (DVD)
Display Laptop Screen Yes X.org i810 driver
CRT / Projector Yes
Screen Rotation Yes* XRandR
Stylus Yes* wacom serial driver.
Power Management Suspend to Disk (hibernate) Yes* Software Suspend 2
Suspend to RAM (ACPI sleep) Yes* Software Suspend 2
Audio Yes ALSA intel8x0 driver
Wireless 802.11b/g Yes ipw2200 drivers
Bluetooth Not Tested See Bluetooth on Fedora Core 4
Card Slots Cardbus Yes yenta_socket driver
SD Card Yes* sdhci driver
Extra Buttons Keyboard Section Yes ibm-acpi driver
Tablet buttons Yes*
Fingerprint Scanner Not Tested
Harddisk Active Protection Not Tested hdapsd

* = Configuration Required

Installation

Installation is fairly simple, most features work out-of-the-box.

Configuration

(Instructions are for KDE)

Tablet Configuration

General tablet configuration is pretty simple.

  • Open Sax2
    • Go to the Tablet section
      • Check Activate This Tablet
      • Select IBM / X41 TABLET PC (SERIAL)
    • Go to the Port and Mode tab
      • Set the port to COM-1 [/dev/ttyS0]
      • Select TCPButton >>> on
      • Select AlwaysCore
      • Select ForceDevice >>> ISDV4
      • Set the mode to Absolute
    • Go to the Electronic Pens tab
      • Check Add Pen
      • Click the Properties button
        • Select TCPButton >>> on
        • Select AlwaysCore
        • Select ForceDevice >>> ISDV4
        • Set the mode to Absolute
    • Save & close Sax2
  • Reboot

The stylus and the PgUp, PgDn, Enter, and Esc tablet buttons should now work after you restart.


Screen Rotation

Basic screen rotation should work out-of-the-box with XRandR, and you can rotate the stylus with xsetwacom

Automatic Rotation

This will make the screen rotate clockwise automatically when you flip the screen to tablet mode.

  • In a shell window, run # xsetwacom list dev
Hint:
The output is the Xorg handle for your stylus, probably Mouse[5]

If not, replace Mouse[5] in the following blocks of code with the correct handle

  • Run as root # kwrite /usr/lib/powersave/scripts/thinkpad_acpi_events
    • When kwrite opens, insert the following lines at line 135:
           20489)   HOTKEY="Tablet Mode"
                    run_on_xserver "xrandr -o 3"
                    run_on_xserver "xsetwacom set Mouse[5] Rotate CW"
                    ACTION="rotate clockwise" ;;
           20490)   HOTKEY="Laptop Mode"
                    run_on_xserver "xrandr -o 0"
                    run_on_xserver "xsetwacom set Mouse[5] Rotate NONE"
                    ACTION="rotate normal" ;;
    • Save & close kwrite

The screen should now rotate clockwise when you flip the screen to tablet mode, and rotate back when you flip it up to laptop mode.


Rotate Button

This will get the rotate button on the tablet working.

  • Run as root # kwrite /usr/bin/rotate_desktop.sh
    • When kwrite pops up, copy & paste the following script into the file
 #!/bin/bash
 ROTATION="$(xrandr -q|grep rotation|grep -o '[\-][\ ][a-z]\+'|grep -o '[a-z]\+')"
 case "$ROTATION" in
 	"normal")
 		xrandr -o 3
 		xsetwacom set Mouse[5] Rotate CW
 		;;
 	"left")
 		xrandr -o 0
 		xsetwacom set Mouse[5] Rotate NONE
 		;;
 	"inverted")
 		xrandr -o 1
 		xsetwacom set Mouse[5] Rotate CCW
 		;;
 	"right")
 		xrandr -o 2
 		xsetwacom set Mouse[5] Rotate HALF
 		;;
 	*)
 		;;
 esac
    • Save & close kwrite
  • Run as root # chmod a+x /usr/bin/rotate_desktop.sh
  • Run as user $ kwrite ~/.Xmodmap
    • When kwrite pops up, copy & paste this into the file
 keycode 203 = XF86RotateWindows
    • Save & close kwrite
  • Open the KDE Control Center
    • Go to the Regional & Accessibility / Input Actions
      • Click New Action
        • Set the Action Name to "Rotate Desktop", or whatever you want to call it
        • Set the Action Type to Keyboard Shortcut -> Command/URL (simple)
      • Select the Keyboard Shortcut tab
        • Click where it says "None"
        • After the little window will pops up, press the rotate button on your tablet, which should set the shortcut to XF86RotateWindows
        • Click ok on the little window
      • Select the Command/URL Settings tab
        • Enter /usr/bin/rotate_desktop.sh in the command field
    • Apply changes & close KDE Control Center

The screen should now rotate when you press the rotate button on your tablet.


Suspend

Suspend to Disk and Suspend to RAM both work fine. This is how to get the stylus back after the system wakes up.

  • Run as root # kwrite /etc/pm/hooks/00clear
    • When kwrite pops up, insert the following code at line 9
 	resume|thaw)
 		setserial /dev/ttyS0 port 0x0200 irq 5 autoconfig
 		;;
    • Save & close kwrite


SD Card

To get the SD card slot working, you just have to tell the kernel to load the right modules.

  • Open YaST
    • Select System, and click on /etc/sysconfig Editor
      • In the /etc/sysconfig Editor, select System / Kernel / MODULES_LOADED_ON_BOOT
        • Enter the following modules, with spaces in between
          • mmc_core
          • mmc_block
          • sdhci
      • Click Finish, apply changes & close /etc/sysconfig Editor
    • Close YaST

The modules will now be loaded each time you boot, and the SD cards should be recognized automatically.

Hint:
If you want to load the modules right away, open a root shell and modprobe them.


Tablet Software

Tablet-oriented programs included on the SuSE DVD...

Xournal

Fast, stable, easy to use pen-based note taking program. The imaging quality is excellent, which makes it nice for drawing also. http://xournal.sf.net

Jarnal

Pen-based note taking program written in Java. Not quite as nice as Xournal, but comes with handwriting recognition. http://www.dklevine.com/general/software/tc1000/jarnal.htm

xvkbd

On-screen keyboard utility. Not much to look at, but it shows up when the screen is locked, which is nice for tablet mode.