Thinkpad on Linux

Remap keys

I am using this to remap keys for faster navigation. When you pres [Fn] key, the cursor arrows are mapped as follows:

[ PGUP ]
[HOME][PGDOWN][END]

keycode 171 = End keycode 172 = Next keycode 173 = Home keycode 174 = Prior
#tested on ThinkPad x201 xmodmap -e "keycode 174 = Prior" xmodmap -e "keycode 172 = Next" xmodmap -e "keycode 173 = Home" xmodmap -e "keycode 171 = End"

ThinkFan

options thinkpad_acpi fan_control=1 fan="level disengaged" beep=6

Vyvazenej konfigurak, pokud to jde, tak je tichej. Ale pokud to je potreba, tak zacne efektivne chladit s nejmensima rozumnejma otackama. Nemelo by to pri bezny praci delat takovy ty narazy, ze je nejdriv vyplej a pak se zas pusti naplno:

(0, 0, 40) (5, 32, 60) (6, 59, 70) (7, 69, 95) ("level disengaged", 90, 32767)
echo thinkpad_acpi >> /etc/modules modprobe thinkpad_acpi systemctl enable thinkfan systemctl start thinkfan

Modem

Pro Vodafone stáhnout tyto oladače a rozbalit do adresáře /lib/firmware/gobi

Nainstalovat balicky apt-get install gobi-loader modemmanager

Nepridavat 05c6:9205 (z lsusb) do /usr/lib/udev/rules.d/60-gobi.rules !!! je to USB ID po nahrani FW, pred nahranim to ma 05c6:9204 a to uz tam je. Pokud se tam nahraje i to prvni, tak to dokola loaduje fw a nenabehne to.

Restartovat pocitac

Po pripojeni skrz networkmanager lze nainstalovat a pouzit program modem-manager-gui k posilani a prijmani SMS, USSD kodu a sledovani detailu pripojeni

odkazy a drivery pro ostatni operatory

http://www.thinkwiki.org/wiki/Qualcomm_Gobi_2000

http://support.lenovo.com/us/en/downloads/ds001302

Thinklight

Dame vsem prisup k LEDkam:

SUBSYSTEM=="leds", ACTION=="add", RUN+="/bin/chmod -R o=u,g=u /sys%p" SUBSYSTEM=="leds", ACTION=="change", ENV{TRIGGER}!="none", RUN+="/bin/chmod -R o=u,g=u /sys%p"

Rebootneme nebo reloadneme udevadm control –reload-rules; udevadm trigger –verbose

Potom vytvorime tenhle skript s pravama pro spusteni:

#!/bin/sh led='/sys/class/leds/tpacpi::thinklight/brightness'; state=$(cat "$led"); [ "$state" == 0 ] && new=255 || new=0; echo "${1:-$new}" > "$led";

Muzem pouzivat tyhle prikazy

thinklight - vypne/zapne svetylko (idealni jako ikonka na listu)

thniklight 0 - vypne

thniklight 255 - zapne