Difference between revisions of "Installing OpenSUSE 10.2 on a ThinkPad X41 Tablet"

From ThinkWiki
Jump to: navigation, search
m (xvkbd)
 
(7 intermediate revisions by 3 users not shown)
Line 56: Line 56:
 
General tablet configuration is pretty simple.
 
General tablet configuration is pretty simple.
  
# Open Sax2
+
* Open Sax2
# Go to the '''Tablet''' section
+
** First, go to the monitor section, we need to fix the screen size
#* Check '''Activate This Tablet'''
+
*** Next to where it says "Monitor:", click the '''Change''' button
#* Select '''IBM / X41 TABLET PC (SERIAL)'''
+
*** The auto-detected monitor is '''-->LCD / 1024X768@75HZ''', which is fine
# Go to the '''Port and Mode''' tab
+
*** Go to the '''Display Size''' tab
#* Set the port to '''COM-1 [/dev/ttyS0]'''
+
**** Enter '''246''' for the X-Axis
#* Select '''TCPButton >>> on'''
+
**** Enter '''184''' for the Y-Axis
#* Select '''AlwaysCore'''
+
*** Click '''OK''' to close the Monitor Settings window
#* Select '''ForceDevice >>> ISDV4'''
+
** Now go to the '''Tablet''' section
#* Set the mode to'''Absolute'''
+
*** Check '''Activate This Tablet'''
# Go to the '''Electronic Pens''' tab
+
*** Select '''IBM / X41 TABLET PC (SERIAL)'''
#* Check '''Add Pen'''
+
** Go to the '''Port and Mode''' tab
#* Click the '''Properties''' button
+
*** Set the port to '''COM-1 [/dev/ttyS0]'''
#** Select '''TCPButton >>> on'''
+
*** Select '''TCPButton >>> on'''
#** Select '''AlwaysCore'''
+
*** Select '''AlwaysCore'''
#** Select '''ForceDevice >>> ISDV4'''
+
*** Select '''ForceDevice >>> ISDV4'''
#** Set the mode to '''Absolute'''
+
*** Set the mode to '''Absolute'''
# Save & close Sax2
+
** Go to the '''Electronic Pens''' tab
# Reboot
+
*** 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.
 
The stylus and the PgUp, PgDn, Enter, and Esc tablet buttons should now work after you restart.
 
 
  
 
=== Screen Rotation ===
 
=== Screen Rotation ===
Line 88: Line 93:
 
This will make the screen rotate clockwise automatically when you flip the screen to tablet mode.
 
This will make the screen rotate clockwise automatically when you flip the screen to tablet mode.
  
# In a shell window, run {{cmdroot|xsetwacom list dev|grep stylus|grep -o '[A-Z][^\ ]\+'}}
+
* In a shell window, run {{cmdroot|xsetwacom list dev|grep stylus|grep -o '[A-Z][^\ ]\+'}}
 
{{HINT| The output is the Xorg handle for your stylus, probably '''Mouse[5]'''
 
{{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}}
 
If not, replace '''Mouse[5]''' in the following blocks of code with the correct handle}}
# Run as root {{cmdroot|kwrite /usr/lib/powersave/scripts/thinkpad_acpi_events}}
+
* Run as root {{cmdroot|kwrite /usr/lib/powersave/scripts/thinkpad_acpi_events}}
# When kwrite opens, insert the following lines at '''line 135''':
+
** When kwrite opens, insert the following lines at '''line 135''':
 
             20489)  HOTKEY="Tablet Mode"
 
             20489)  HOTKEY="Tablet Mode"
 
                     run_on_xserver "xrandr -o 3"
 
                     run_on_xserver "xrandr -o 3"
Line 101: Line 106:
 
                     run_on_xserver "xsetwacom set '''Mouse[5]''' Rotate NONE"
 
                     run_on_xserver "xsetwacom set '''Mouse[5]''' Rotate NONE"
 
                     ACTION="rotate normal" ;;
 
                     ACTION="rotate normal" ;;
 
+
** Save & close kwrite
# Save & close
+
  
 
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.
 
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.
Line 111: Line 115:
 
This will get the rotate button on the tablet working.
 
This will get the rotate button on the tablet working.
  
# Run as root {{cmdroot|kwrite /usr/bin/rotate_desktop.sh}}
+
* Run as root {{cmdroot|kwrite /usr/bin/rotate_desktop.sh}}
#* When kwrite pops up, copy & paste the following script into the file
+
** When kwrite pops up, copy & paste the following script into the file
 
   #!/bin/bash
 
   #!/bin/bash
 
   ROTATION="$(xrandr -q|grep rotation|grep -o '[\-][\ ][a-z]\+'|grep -o '[a-z]\+')"
 
   ROTATION="$(xrandr -q|grep rotation|grep -o '[\-][\ ][a-z]\+'|grep -o '[a-z]\+')"
 
 
 
   case "$ROTATION" in
 
   case "$ROTATION" in
 
   "normal")
 
   "normal")
Line 136: Line 139:
 
   ;;
 
   ;;
 
   esac
 
   esac
# Save & close
+
** Save & close kwrite
# Run as root {{cmdroot|chmod a+x /usr/bin/rotate_desktop.sh}}
+
* Run as root {{cmdroot|chmod a+x /usr/bin/rotate_desktop.sh}}
# Run as user {{cmduser|kwrite ~/.Xmodmap}}
+
* Run as user {{cmduser|kwrite ~/.Xmodmap}}
#* When kwrite pops up, copy & paste this into the file
+
** When kwrite pops up, copy & paste this into the file
 
   keycode 203 = XF86RotateWindows
 
   keycode 203 = XF86RotateWindows
# Open the KDE Control Center
+
** Save & close kwrite
# Go to the '''Regional & Accessibility / Input Actions'''
+
* Open the KDE Control Center
#* Click '''New Action'''
+
** Go to the '''Regional & Accessibility / Input Actions'''
#** Set the Action Name to '''"Rotate Desktop"''', or whatever you want to call it
+
*** Click '''New Action'''
#** Set the Action Type to '''Keyboard Shortcut -> Command/URL (simple)'''
+
**** Set the Action Name to '''"Rotate Desktop"''', or whatever you want to call it
#* Select the '''Keyboard Shortcut''' tab
+
**** Set the Action Type to '''Keyboard Shortcut -> Command/URL (simple)'''
#** Click where it says '''"None"'''
+
*** Select the '''Keyboard Shortcut''' tab
#** After the little window will pops up, press the rotate button on your tablet, which should set the shortcut to '''XF86RotateWindows'''
+
**** Click where it says '''"None"'''
#** Click ok on the little window
+
**** After the little window will pops up, press the rotate button on your tablet, which should set the shortcut to '''XF86RotateWindows'''
#* Select the '''Command/URL Settings''' tab
+
**** Click ok on the little window
#** Enter '''/usr/bin/rotate_desktop.sh''' in the command field
+
*** Select the '''Command/URL Settings''' tab
# Apply changes & close
+
**** 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.
 
The screen should now rotate when you press the rotate button on your tablet.
Line 162: Line 166:
 
This is how to get the stylus back after the system wakes up.
 
This is how to get the stylus back after the system wakes up.
  
# Run as root {{cmdroot|kwrite /etc/pm/hooks/00clear}}
+
* Run as root {{cmdroot|kwrite /etc/pm/hooks/00clear}}
# Insert the following code at '''line 9'''
+
** When kwrite pops up, insert the following code at '''line 9'''
 
   resume|thaw)
 
   resume|thaw)
 
   setserial /dev/ttyS0 port 0x0200 irq 5 autoconfig
 
   setserial /dev/ttyS0 port 0x0200 irq 5 autoconfig
 
   ;;
 
   ;;
# Save & close
+
** Save & close kwrite
  
  
Line 174: Line 178:
 
To get the SD card slot working, you just have to tell the kernel to load the right modules.
 
To get the SD card slot working, you just have to tell the kernel to load the right modules.
  
# Open YaST
+
* Open YaST
# Select '''System''', and click on '''/etc/sysconfig Editor'''
+
** Select '''System''', and click on '''/etc/sysconfig Editor'''
# In the /etc/sysconfig Editor, select '''System / Kernel / MODULES_LOADED_ON_BOOT'''
+
*** In the /etc/sysconfig Editor, select '''System / Kernel / MODULES_LOADED_ON_BOOT'''
#* Enter the following modules, with spaces in between
+
**** Enter the following modules, with spaces in between
#** '''mmc_core'''
+
***** '''mmc_core'''
#** '''mmc_block'''
+
***** '''mmc_block'''
#** '''sdhci'''
+
***** '''sdhci'''
# Click '''Finish''', apply changes & close
+
*** 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.
 
The modules will now be loaded each time you boot, and the SD cards should be recognized automatically.
Line 204: Line 209:
  
 
On-screen keyboard utility.  Not much to look at, but it shows up when the screen is locked, which is nice for tablet mode.
 
On-screen keyboard utility.  Not much to look at, but it shows up when the screen is locked, which is nice for tablet mode.
 +
http://homepage3.nifty.com/tsato/xvkbd/
  
  
[[Category:X41 Tablet]][[Category:SuSE]]
+
[[Category:X41 Tablet]][[Category:OpenSUSE]]

Latest revision as of 22:24, 22 September 2007

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
    • First, go to the monitor section, we need to fix the screen size
      • Next to where it says "Monitor:", click the Change button
      • The auto-detected monitor is -->LCD / 1024X768@75HZ, which is fine
      • Go to the Display Size tab
        • Enter 246 for the X-Axis
        • Enter 184 for the Y-Axis
      • Click OK to close the Monitor Settings window
    • Now 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. http://homepage3.nifty.com/tsato/xvkbd/