https://www.thinkwiki.org/w/api.php?action=feedcontributions&user=Gorillagorillagorilla&feedformat=atomThinkWiki - User contributions [en]2024-03-28T11:36:52ZUser contributionsMediaWiki 1.31.12https://www.thinkwiki.org/w/index.php?title=Installing_Gentoo_on_a_ThinkPad_X60_Tablet&diff=37692Installing Gentoo on a ThinkPad X60 Tablet2008-05-10T14:08:43Z<p>Gorillagorillagorilla: /* Gentoo General */ suspend2-sources no longer exist. They are now tuxonice-sources.</p>
<hr />
<div>= Gentoo General =<br />
<br />
Some general apps are needed, these are installed:<br />
emerge thinkpad<br />
echo "thinkpad" >> /etc/modules.autoload.d/kernel-2.6<br />
<br />
TODO:<br />
echo "app-laptop/hdapsd" >> /etc/portage/package.keywords<br />
emerge hdapsd app-laptop/tp_smapi<br />
rc-update add hdapsd default<br />
/etc/init.d/hdapsd start<br />
<br />
= Sound =<br />
NOTE: If you get an hda_intel probe error on boot, you have to enable modem support in bios (don't ask why!).<br />
<br />
In the kernel configuration:<br />
Device Drivers ---><br />
Sound ---><br />
Advanced Linux Sound Architecture ---><br />
PCI devices ---><br />
<*> Intel HD Audio<br />
Now emerge alsa-utils and add alsasound to the default runlevel:<br />
emerge -av alsa-utils<br />
rc-update add alsasound default<br />
/etc/init.d/alsasound start<br />
Unmute the sound using alsamixer by pressing the m key on the Master and PCM sliders (MM=Muted / 00=Not muted)<br />
<br />
= Display =<br />
In the kernel configuration:<br />
Device Drivers ---><br />
Character devices ---><br />
<*> Direct Rendering Manager<br />
<*> Intel 830M, 845G, 852GM, 855GM, 865G (i915 driver) ---><br />
Now run xorgcfg which should start smoothly. Do your personal changes (none), and save the files to their default location.<br />
Edit {{path|/etc/X11/xorg.conf}} and add the following lines:<br />
Section "dri"<br />
Mode 0666<br />
EndSection<br />
<br />
Now for the rotation to work, we need to emerge some stuff, and make some editing.<br />
First, emerge some apps (note: wee need linuxwacom >= 0.7.8)<br />
echo "x11-drivers/linuxwacom" >> /etc/portage/package.keywords<br />
emerge linuxwacom sudo xhost xrandr<br />
<br />
Get the rotate script from ref. A, and make some adjustments:<br />
cd /usr/local/bin<br />
wget http://luke.no-ip.org/x60tablet/examples/rotate<br />
chmod +x rotate<br />
sed "s/cursor/Cursor/" -i rotate<br />
sed "s/stylus/Stylus/" -i rotate<br />
sed "s/eraser/Eraser/" -i rotate<br />
sed 's/"%s set %s Rotate %s"/"sudo su -c \\"DISPLAY=:0.0 %s set %s Rotate %s\\""/' -i rotate<br />
sed "s/'normal': 'NONE', 'left': 'CCW', 'right': 'CW', 'inverted': 'HALF'/'normal': '0', 'left': '2', 'right': '1', 'inverted': '3'/" -i rotate<br />
<br />
Put yourself into the wheel group, and setup sudo to make you run xsetwacom without password.<br />
<br />
{{HINT|For the compiz-fusion to work you will need to start it like this:<br />
<nowiki>LIBGL_ALWAYS_INDIRECT=true compiz-fusion --replace --indirect-rendering ccp</nowiki>}}<br />
<br />
TODO: xhost +<br />
<br />
= Input =<br />
== Pen ==<br />
In the kernel configuration:<br />
Device Drivers ---><br />
Input device support ---><br />
<*> Event interface<br />
[*] Miscellaneous devices ---><br />
<*> User level driver support<br />
USB support ---><br />
< > Wacom Intuos/Graphire tablet support<br />
<br />
The Wacom Intus/Graphire USB Tablet should not be activated, the X60 Tablet is not an USB device.<br />
<br />
Emerge setserial;<br />
emerge setserial<br />
and add the following (magic) line to {{path|/etc/conf.d/local.start}}:<br />
setserial /dev/ttyS0 port 0x0200 irq 5 autoconfig<br />
<br />
If you get 'Cannot set serial info: Invalid argument' your kernel may have slightly broken serial support (suspend2-sources-2.6.22-r2, gentoo-sources-2.6.22-r5), this is fixed in gentoo-sources-2.6.22-r9.<br />
<br />
{{WARN|Xorg 7.3 works with current linuxwacom (0.7.8-3, 0.7.9-1), but in a strange way. Keep Xorg 7.2 unless you are going to use your pen only as mouse and only in the normal rotation.}}<br />
'''Re to ATTENTION!''' I reply to myself. In the linuxwacom 0.7.8 branch they added the support for the multitouch feature. However this "feature" makes the usage of pen almost impossible (see [http://sourceforge.net/forum/forum.php?thread_id=1777969&forum_id=236872 this forum]). I prepared a patch which removes this feature and wrote an ebuild which can apply this patch: [https://bugs.gentoo.org/show_bug.cgi?id=147537 Bugzilla Bug 147537]. However still I have small problems in Xorg 7.3: [http://sourceforge.net/tracker/index.php?func=detail&aid=1823908&group_id=69596&atid=525124 bug 1823908]<br />
<br />
Now add the following lines to your xorgcfg generated {{path|/etc/X11/xorg.conf}}:<br />
Section "InputDevice"<br />
Identifier "Cursor"<br />
Driver "wacom"<br />
Option "Device" "/dev/ttyS0"<br />
Option "Type" "cursor"<br />
Option "ForceDevice" "ISDV4"<br />
EndSection<br />
Section "InputDevice"<br />
Identifier "Stylus"<br />
Driver "wacom"<br />
Option "Device" "/dev/ttyS0"<br />
Option "Type" "stylus"<br />
Option "ForceDevice" "ISDV4"<br />
EndSection<br />
Section "InputDevice"<br />
Identifier "Eraser"<br />
Driver "wacom"<br />
Option "Device" "/dev/ttyS0"<br />
Option "Type" "eraser"<br />
Option "ForceDevice" "ISDV4"<br />
EndSection<br />
<br />
And the following three lines in the end of the ServerLayout section:<br />
InputDevice "Cursor" "SendCoreEvents"<br />
InputDevice "Stylus" "SendCoreEvents"<br />
InputDevice "Eraser" "SendCoreEvents"<br />
<br />
=== Xournal ===<br />
The ebuild in [http://bugs.gentoo.org/show_bug.cgi?id=143177 Bug 143177] works fine for verion 0.4.1<br />
<br />
== Touch Screen ==<br />
<br />
It works for me from the box. I just unexpectedly discovered that it works. However in the "left" and "right" rotations of the screen the pointer appears approximately 3cm from the touch point. I do not know how to solve this.<br />
<br />
However it causes a lot of problem so I prepared a sollution (see the reply to attention above: [http://www.thinkwiki.org/wiki/installing_Gentoo_on_a_ThinkPad_X60_Tablet#Pen]).<br />
<br />
== Trackpoint ==<br />
Works.<br />
<br />
== Fingerprint Reader ==<br />
This actually is surprisingly easy to make work:) Just emerge thinkfinger >= 0.3;<br />
echo "sys-auth/thinkfinger" >> /etc/portage/package.keywords<br />
emerge thinkfinger<br />
and add the following line in {{path|/etc/pam.d/system-auth}}:<br />
auth sufficient pam_thinkfinger.so<br />
<br />
The first section in the file should now look like the following:<br />
auth required pam_env.so<br />
auth sufficient pam_thinkfinger.so<br />
auth sufficient pam_unix.so try_first_pass likeauth nullok<br />
<br />
All left is to read your fingerprint for your user. Run tf-tool --add-user <login>, then reboot and see if it works.<br />
If using gdm, it should work smoothly.<br />
<br />
==Thinkpad buttons==<br />
You can enable them in the kernel either built-in or as a module:<br />
<br />
Location: │<br />
-> Device Drivers │<br />
-> Character devices<br />
<M> /dev/nvram support<br />
<br />
In case you chose the module you will need to autoload it since it is not loaded by the udev:<br />
echo nvram >> /etc/modules.autoload.d/kernel-2.6<br />
<br />
By default the /dev/nvram device is configured for root only access. In order to change it permanentely add the corresponding rule to udev. For example I did:<br />
echo "KERNEL==\"nvram\", GROUP=\"users\"" >> /etc/udev/rules.d/50-local.rules<br />
<br />
After that you can either configure them using app-laptop/tpb or KDE user can relay on the KMilo application configurable in the <br />
"Control Center -> System Administration -> IBM Thinkpad Laptop".<br />
<br />
= Network =<br />
== Ethernet ==<br />
In the kernel configuration:<br />
Device Drivers ---><br />
Network device support ---><br />
Ethernet (1000 Mbit) ---><br />
<*> Intel(R) PRO/1000 Gigabit Ethernet support<br />
<br />
Configure the ethernet card in {{path|/etc/conf.d/net}}:<br />
config_eth0="dhcp"<br />
eth0_dhcpcd="-t 4"<br />
<br />
== Wireless ==<br />
Note: Make sure that the hardware disable-switch isn't disabled - it is placed at the front/bottom of the laptop (don't make the same mistake as i did!)<br />
<br />
In the kernel configuration:<br />
Device Drivers ---><br />
Network device support ---><br />
Wireless LAN (non-hamradio) ---><br />
[*] Wireless LAN drivers (non-hamradio) & Wireless Extensions<br />
Networking ---><br />
<*> Generic IEEE 802.11 Networking Stack<br />
<M> IEEE 802.11i CCMP support<br />
<M> IEEE 802.11i TKIP encryption<br />
<br />
Now, emerge ipw3945, wireless-tools > 22 and wpa_supplicant, and add ipw3945d to the default runlevel by issuing:<br />
echo "net-wireless/wireless-tools" >> /etc/portage/package.keywords<br />
emerge ipw3945 wireless-tools wpa_supplicant<br />
rc-update add ipw3945d default<br />
/etc/init.d/ipw3945d start<br />
<br />
Configure the wireless card in {{path|/etc/conf.d/net}}:<br />
config_eth1="dhcp"<br />
eth1_dhcpcd="-t 4"<br />
eth1_modules="wpa_supplicant"<br />
wpa_supplicant_eth1="-Dwext"<br />
<br />
If you are a kismet user it should be configured as follows in {{path|/etc/kismet.conf}}:<br />
suiduser=<login><br />
source=ipw3945,eth1,ipw3945<br />
<br />
== VPN ==<br />
To come...<br />
<br />
== Bluetooth ==<br />
In the kernel configuration:<br />
Networking ---><br />
<*> Bluetooth subsystem support ---><br />
<*> L2CAP protocol support<br />
<*> RFCOMM protocol support<br />
[*] RFCOMM TTY support<br />
Bluetooth device drivers ---><br />
<*> HCI USB driver<br />
<br />
Now emerge bluez-utils;<br />
emerge bluez-utils<br />
and configure your display name in the device section in {{path|/etc/bluetooth/hcid.conf}}:<br />
name "Your Displayname"<br />
<br />
Now we are ready to start<br />
rc-update add bluetooth default<br />
/etc/init.d/bluetooth start<br />
<br />
= External Connections =<br />
<br />
= ACPI =<br />
Just emerge the acpi daemon:<br />
emerge acpid<br />
rc-update add acpid default<br />
/etc/init.d/acpid start<br />
<br />
= Extra Features =<br />
<br />
= History =<br />
5. July - Initial release.<br />
<br />
24. July - Added Gentoo General, Sound, Some kernel configuration for the 2.6.21 kernel and new keycodes.<br />
<br />
2. September - All sections are has been polished, and should work properly. Only the last ones are missing.<br />
<br />
= External Sources =<br />
A) [http://luke.no-ip.org/x60tablet/ Linux on the X60 Tablet]<br />
<br />
B) [http://www.comptechdoc.org/os/linux/howlinuxworks/linux_hlkeycodes.html] Keycode Table<br />
<br />
<br />
[[Category:Gentoo]]</div>Gorillagorillagorilla