Difference between revisions of "Installing Ubuntu 10.04 (Lucid Lynx) on a ThinkPad X61 Tablet"
m (Edit wacom device names in rotate script .)
|Line 277:||Line 277:|
# rotate the stylus
# rotate the stylus
for type in
for type in eraser; do
/usr/bin/xsetwacom set $type rotate $NEW_WACOM
/usr/bin/xsetwacom set $typerotate $NEW_WACOM
Revision as of 00:12, 3 April 2010
This is a notes page for now. It will improve with time I have blatantly copied the 9.04 page as a template.
- 1 Introduction
- 2 Fixing Touch
- 3 Fixing the Tablet Toolbox Button
- 4 Setup the Tablet Control-Alt-Delete Button
- 5 Setup the Tablet Rotate Button
- 6 Setup the Middle Button Scrolling
- 7 Setup ThinkVantage Button
- 8 Setup Magnify Fn Button
- 9 Setup Fingerprint Reader
- 10 Setup Automatic Screen Rotation
- 11 Setup ThinkVantage ActiveProtection
- 12 Useful Task: Disable Bluetooth on Startup
- 13 Useful Task: Enable Laptop Mode
- 14 Optional Task: Adjusting Trackpoint Settings
- 15 Sources
This page covers the additional hardware setup required after installing Ubuntu 10.04 Jaunty to make the Thinkpad X61 Tablet Fully Functional.
Audio Buttons, Brightness Fn Buttons, Radio Fn Button, Suspend Fn Button, Tablet L/R/U/D Buttons, Tablet Enter Button, Tablet Esc Button, NumberLock Fn Button, Tablet Pen, Wireless Radio,
Forward / Back Buttons, Power Fn Button, Lock Fn Button, Hibernate Fn Button, Media Fn Buttons Bluetooth Radio,
What Almost Works
Tablet Toolbox Button - causes lock or suspend, Tablet Touch – Requires Calibration,
What Does Not Work
Tablet Control-Alt-Delete Button, Tablet Rotate Button, Middle Mouse Button, ThinkVantage Button, Magnify Fn Button, Fingerprint Reader, Automatic Screen Rotation, ThinkVantage ActiveProtection,
Works out of the box, just needs some calibration.
Wacomcpl is no longer available in 10.04. The new package is xserver-xorg-input-wacom. How to calibrate the screen is being looked into. The xsetwacom command is still intact to set the calibrations though.
The Wacom Tablet in the X61t is a serial Wacom tablet. It can be configured by using wacomcpl. Wacomcpl is part of the wacom-tools package and can be retrieved in apt:
sudo apt-get install wacom-tools
After this wacomcpl can be run by typing:
Unfortunately HAL assigns names to wacom devices in a way that the recent wacomcpl from jaunty cant find them, to help wacomcpl to find them:
Open a terminal and type:
sudo gedit /etc/init.d/wacomtohal
and paste this code in:
#! /bin/sh ## find any wacom devices for udi in `hal-find-by-property --key input.x11_driver --string wacom` do type=`hal-get-property --udi $udi --key input.x11_options.Type` ## rewrite the names that the Xserver will use hal-set-property --udi $udi --key info.product --string $type done
then run :
sudo chmod +x /etc/init.d/wacomtohal sudo update-rc.d wacomtohal defaults 27
now reboot and launch wacomcpl
Making Wacomcpl Settings Restore on Reboot
If you lose your calibration after reboot:
sudo gedit ~/.xinitrc
Find the line that says:
and change it to
Save and exit.
Go to System>Preferences>Startup Applications and create a new entry named whatever you want.
The command should be:
Your wacomcpl settings will now restore on reboot
Fixing the Tablet Toolbox Button
This key needs to be set to a keycode. Pick any empty one (241 is usually empty)
sudo setkeycodes 68 241
Now you can bind this key to any command.
Setup the Tablet Control-Alt-Delete Button
This key needs to be set to a keycode. Pick any empty one (242 is usually empty)
sudo setkeycodes 67 242
Now you can bind this key to any command.
Setup the Tablet Rotate Button
This key needs to be set to a keycode. Pick any empty one (240 is usually empty)
sudo setkeycodes 6c 240
Now you can bind this key to any command. (It should be possible to write a script to interact with the autorotate given on this page)
Setup the Middle Button Scrolling
Open a terminal and run:
xinput set-prop '"TPPS/2 IBM TrackPoint"' "Evdev Wheel Emulation" 1 xinput set-prop '"TPPS/2 IBM TrackPoint"' "Evdev Wheel Emulation Button" 2 xinput set-prop '"TPPS/2 IBM TrackPoint"' "Evdev Wheel Emulation Timeout" 200
for vertical scrolling. Add the following as well if you want horizontal scrolling:
xinput set-prop '"TPPS/2 IBM TrackPoint"' "Evdev Wheel Emulation Axes" 6 7 4 5
You will need to run this every time you restart your computer but if you can add it to a script and add it to ~/.kde/Autostart (in Kubuntu) so it will run automatically everytime you log in to KDE.
HAL has been deprecated so the following might still work but is not suggested: Create a new file called /etc/hal/fdi/policy/mouse-wheel.fdi typing:
sudo gedit /etc/hal/fdi/policy/mouse-wheel.fdi
And fill it with this code:
<?xml version="1.0" encoding="UTF-8"?> <match key="info.product" string="TPPS/2 IBM TrackPoint"> <merge key="input.x11_options.EmulateWheel" type="string">true</merge> <merge key="input.x11_options.EmulateWheelButton" type="string">2</merge> <merge key="input.x11_options.XAxisMapping" type="string">6 7</merge> <merge key="input.x11_options.YAxisMapping" type="string">4 5</merge> <merge key="input.x11_options.ZAxsisMapping" type="string">4 5</merge> <merge key="input.x11_options.Emulate3Buttons" type="string">true</merge> </match>
Setup ThinkVantage Button
The ThinkVantage button does not work only in that it is not bound to anything. To bind it go to System>Preferences>Keyboard Shortcuts and set it to perform any command.
Setup Magnify Fn Button
No Solution Yet.
Setup Fingerprint Reader
The Thinkfinger driver works fine on the X61. The following is the paraphrased commands from the installing thinkfinger page that are relevant to the X61 and Ubuntu 9.04.
In terminal, add a key:
sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com F2A12FABE936A7BBDC4EA33351DB180D1323E149
Add the PPA repositories to your sources.list (/etc/apt/sources.list):
deb http://ppa.launchpad.net/jon-oberheide/ppa/ubuntu jaunty main deb-src http://ppa.launchpad.net/jon-oberheide/ppa/ubuntu jaunty main
sudo apt-get update
sudo apt-get install thinkfinger-tools libpam-thinkfinger
Now the driver is installed and should be working. You can try it (as root) with
sudo tf-tool --acquire
sudo tf-tool --verify
This will ask you to swipe your finger three times, save the fingerprint to /tmp/test.bir and then verify your fingerprint with the bir-file.
tf-tool --acquire $USERNAME
Optional: Change the login screen to allow keyboard-less login:
Go to: System>Administration>Login Window
Click on the 'Local' tab.
Set the drop-down boxes to: 'Themed with face browser' and 'Selected Only' and choose 'Human List' from the list of logins.
Note: it may take some time for the reader to startup, give it 5 seconds before use and before pressing enter to initiate login.
Setup Automatic Screen Rotation
The following was inspired by Installing Ubuntu 8.10 (Intrepid Ibex) on an X61 Tablet, with some minor additions:
- put the following in /etc/acpi/events/lenovo-rotate-normal
# /etc/acpi/events/lenovo-rotate-normal # This is called when the user rotates the screen to laptop mode event=ibm/hotkey HKEY 00000080 0000500a action=/etc/acpi/thinkpad-rotatescreen.sh right
- put the following in /etc/acpi/events/lenovo-rotate-tablet
# /etc/acpi/events/lenovo-rotate-tablet # This is called when the user rotates the screen to tablet mode event=ibm/hotkey HKEY 00000080 00005009 action=/etc/acpi/thinkpad-rotatescreen.sh normal
- put the following in /etc/acpi/thinkpad-rotatescreen.sh and make it executable
#!/bin/sh # # This script rotates the display in TabletPCs when screen is changed from # laptop to tablet mode, or when rotation button is pressed test -f /usr/share/acpi-support/key-constants || exit 0 . /usr/share/acpi-support/power-funcs # i'm not trusting this ... #if [ -f /var/lib/acpi-support/screen-rotation ] ; then # ROTATION=`cat /var/lib/acpi-support/screen-rotation` #fi # ... and thus calling this with a parameter ROTATION="$1" # this should be called "ROTATION_FROM" case "$ROTATION" in right) NEW_ROTATION="normal" NEW_WACOM="none" ;; *) NEW_ROTATION="right" NEW_WACOM="cw" ;; esac for x in /tmp/.X11-unix/*; do displaynum=`echo $x | sed s#/tmp/.X11-unix/X##` getXconsole; if [ x"$XAUTHORITY" != x"" ]; then export DISPLAY=":$displaynum" /usr/bin/xrandr -o $NEW_ROTATION && echo $NEW_ROTATION > /var/lib/acpi-support/screen-rotation # rotate the stylus for type in "Serial Wacom Tablet eraser" "Serial Wacom Tablet touch" "Serial Wacom Tablet" ; do /usr/bin/xsetwacom set "$type" rotate $NEW_WACOM done # rotate the arrow keys case "$NEW_ROTATION" in right) xmodmap - <<END keycode 114 = Up NoSymbol Up NoSymbol Up keycode 111 = Left NoSymbol Left NoSymbol Left keycode 116 = Right NoSymbol Right NoSymbol Right keycode 113 = Down NoSymbol Down NoSymbol Down END ;; *) xmodmap - <<END keycode 111 = Up NoSymbol Up NoSymbol Up keycode 113 = Left NoSymbol Left NoSymbol Left keycode 114 = Right NoSymbol Right NoSymbol Right keycode 116 = Down NoSymbol Down NoSymbol Down END ;; esac fi done
Note: check the output of
xsetwacom list dev
to identify the devices to put in the line
for type in stylus eraser cursor ; do
My system has a touch device and not a cursor device.
Setup ThinkVantage ActiveProtection
No Solution Yet.
Useful Task: Disable Bluetooth on Startup
These instructions will disable the bluetooth radio being activated during the boot. The radio can then be activated at the users discretion using Fn F5 (Radio Fn Button).
edit /etc/rc.local and add:
chmod 666 /proc/acpi/ibm/bluetooth echo "disable" > /proc/acpi/ibm/bluetooth
before the 'exit 0' line
- note chmod 666 makes this file editable by everyone, this may compromise security, try different settings to find the one that suits your needs (655 may work)
- note proc is depreciated and may not work in future releases
Useful Task: Enable Laptop Mode
Laptop mode is a power saving tool that allows the hard drive to spin down to conserve battery power. This is disabled by default as it has been known to cause problems on some computers, but it appears to work on the X61t.
- Warning: Laptop mode stores data in ram teporarily until it needs to write to disk. Power Loss in laptop mode could lead to significant data loss.
- Warning: Excessive spin-up spin-down cycles will wear out your hard drive much more quickly than normal use. Be careful when configuring laptop mode settings.
- Warning: Do Not Use Laptop Mode if you have a SSD. It is for platter drives only.
sudo gedit /etc/default/acpi-support
Configure Laptop Mode
sudo gedit /etc/laptop-mode/laptop-mode.conf
Optional Task: Adjusting Trackpoint Settings
If you find that your trackpoint pointer is too slow, use control-trackpoint to adjust your settings.
To install, install sysfsutils first, as per tpctl's documentaton
sudo apt-get install sysfsutils
then install the .deb from sourceforge (the graphical installer worked for me). Once installed, run:
The above is a compilation of my notes from when I installed Jaunty on my X61t. The code and many of the instructions come from various pages and sources around the Internet. I will attempt to document them when time permits. If you see anything that should be added or wish to cite a source I missed, please edit the page.