User Tools

Site Tools


Sidebar

hardwarerelated:thinkpad_t41

using the 2 keys next to cursor-keys

xev         # select the window that gets created and hit the keys after each other to get their keycodes. here 234 and 233
xmodmap -pk # shows current mappings
xmodmap -e 'keycode 233 = THORN'
xmodmap -e 'keycode 234 = Oslash'
            # those commands now maps keysyms to our keys, use keysyms you do not usually
WPrefs      # this is the utilits windowmaker uses to assign actions. Go to 'change keyboard shortcuts', select your action
            # (for me its switch to next/previous workspace), then 'capture' and hit the key. save, and the keys have their
            # new assignment.
            # execute the 2 assignment-xmodmap-calls in ~/.xinitrc or ~/.xsession, or read on .xmodmaprc in 'man xmodmap'

things to install on a fresh linux/bsd on the thinkpad

  • wmaker, xorg
  • thinkpad-virtualscreen-keys
  • firefox, adblockerplugin, (privoxy)
  • umts
  • acpi, suspend to disc/ram
  • qemu+kqemu
  • mplayer
  • madwifi-driver + kismet
  • sounddriver + xmms + mpg123
  • OpenSwan + patches, KLIPS, OpenSC + patches
  • OpenVPN
  • fglrx not any more since 3d-seems broken (no textures on 4d-graphics) and the mobility9000-support was droped in last version
  • imagemagick, qiv

a word on wlan-driver

I have an atheros-chip for wlan. The old madwifi-driver works in hostap-mode (so providing an access point). The newer ath5k driver does station/managed and monitor mode, but for now hostap-mode is restricted to open networks as it seems as of 2008-11-14 . See http://marc.info/?l=linux-wireless&m=122665779201442&w=2

setup wlan-card as accesspoint with wpa/wpa2

# install madwifi-driver and load it (modprobe ath_pci)
cd /tmp
wget http://ftp.debian.org/debian/pool/main/h/hostapd/hostapd_0.5.5.orig.tar.gz # or get latest from http://hostap.epitest.fi/releases/
tar xzf hostapd_0.5.5.orig.tar.gz
cd hostapd-0.5.5/
cp defconfig .config
vi .config
> CONFIG_DRIVER_MADWIFI=y
> CFLAGS += -I/usr/src/madwifi-0.9.2.1
make && cp hostapd /usr/local/sbin
umask 377
cat >/etc/hostapd/hostapd.conf.works3 <<EOF
interface=ath0
driver=madwifi
logger_syslog=-1
logger_syslog_level=2
logger_stdout=-1
logger_stdout_level=2
debug=0
dump_file=/tmp/hostapd.dump
ctrl_interface=/var/run/hostapd
ctrl_interface_group=0
ssid=fluxnet
macaddr_acl=0
auth_algs=3
eapol_key_index_workaround=0
eap_server=0
# wpa=3
wpa=1
wpa_passphrase=545w3dfwdxyf35
wpa_key_mgmt=WPA-PSK
wpa_pairwise=TKIP CCMP
wpa_group_rekey=600
EOF

wlanconfig ath0 destroy
wlanconfig ath0 create wlandev wifi0 wlanmode ap
iwpriv ath0 mode 0 # set mode, 1=11a only, 2=11b only, 3=11g only, 0=autoselect from 11a/b/g (default)
hostapd /etc/hostapd/hostapd.conf.works3
ifconfig ath0 10.0.3.1/24
ifconfig ath0 10.0.3.1/24

cat >/etc/dhcpd.conf <<EOF
option domain-name-servers 10.0.3.1;

subnet 10.0.3.0 netmask 255.255.255.0 {
  range 10.0.3.10 10.0.3.100;
  option routers 10.0.3.0.1;
}
EOF

/etc/init.d/dhcpd start
sysctl -w net.ipv4.ip_forward=1
iptables -A POSTROUTING -t nat -o ppp0 -s 10.0.3.0/24  -j MASQUERADE

setup wlan-card as client with wpa/wpa2

apt-get install wpasupplicant # or install from http://hostap.epitest.fi/wpa_supplicant/
umask 127
wpa_passphrase fluxnet 545w3dfwdxyf35 >/etc/wpa_supplicant.conf
# add those lines to the network-section in file /etc/wpa_supplicant.conf
----------
        key_mgmt=WPA-PSK
        # proto=WPA     # WPA1
        proto=RSN       # WPA2
----------

modprobe ath_pci
wlanconfig ath0 create wlandev wifi0 wlanmode sta
iwconfig ath0 essid fluxnet mode managed
wpa_supplicant -B -Dmadwifi -iath0 -c/etc/wpa_supplicant.conf
# wpa_supplicant -Dwext -iath0 -c/etc/wpa_supplicant.conf # for ath5k driver, foreground
dhclient ath0

setup and use hdaps (angle-sensor)

  • compile and install a kernel >=2.6.14 with the hdaps option and the joydev-module (its in input-devices)
  • load the two modules
  • install neverball or tuxracer and use the thinkpad to control the game
hardwarerelated/thinkpad_t41.txt · Last modified: 2015/08/11 20:32 (external edit)