T61p/Debian/Gnome/Gsynaptics HOWTO

gsynaptics gives you a nice little GUI in gnome to control the options on your synaptics touchpad, like the one my T61p came with. It’s easy to set up on a default debian install, you just need to add a few stanazas to your xorg.conf

Here’s the edits I needed from a default install xorg.conf:

  1. Make a backup of your current xorg.conf
  2. Remove the “Generic Mouse” section. You don’t need it anymore.
  3. Add a section for your touchpad like so:

    Section "InputDevice"
      Identifier "Synaptics Touchpad"
      Driver "synaptics"
      Option "SendCoreEvents" "true"
      Option "Protocol" "auto-dev"
      Option "Device" "/dev/psaux"
      Option "SHMConfig" "true"
    EndSection

  4. And add a line in your “ServerLayout” section referencing your new synaptics section. I didn’t have a ServerLayout section so I had to add one, mine looks like this:

    Section "ServerLayout"
      Identifier "Default Layout"
      Screen "Default Screen"
      InputDevice "Generic Keyboard"
      InputDevice "Synaptics Touchpad"
    EndSection

Now save everything you’re doing and then restart X11 by hitting cntrl-alt-backspace. If X won’t start back up, you can hit cntrl-alt-f1 and log in at a command prompt, restore your xorg.conf from the backup you made earlier, then run /etc/init.d/gdm restart.

In the event that things just aren’t working, your friend is /var/log/Xorg.0.log. That log file contains the results of your x-server’s parsing of your xorg.conf.

Comments (1)

T61p, Gnome, and Swapping ESC/CapsLock

CapsLock… who needs it?  If you’ve got a CapsLock problem, there is help.  Otherwise, if you happen to be an vi addict, then swapping CapsLock with ESC is pretty awesome since that Meta key is only rivaled by the space bar in terms of key presses per second.

Nowdays, a default Debian install with Gnome comes with a gnome-control-center capplet for gnome-keyboard-properties. If you go System->Preferences->Keyboard->Layouts->Layout Options->CapsLock Key behavior->”Swap ESC and CapsLock” then your ESC and CapsLock are swapped. More or less. I found a few problems with this on my T61p.

  • The little Thinkpad CapsLock LED does not do the swap.  It will toggle as you hit your new Meta (ESC) key, not your new CapsLock key.
  • Hibernation:  Depending on what combo of ESC and CapsLock are set when you initiate hibernation, when you come out of hibernation they can be in an inconsistent state.  The only GUI solution I’ve found to this is to reset my Keyboard Layout Options to the defaults, and then do the “Swap ESC and CapsLock” GUI chain again.  (No, I haven’t tracked this bug down and filed a report… I suspect it’s somehow unique to Thinkpads.)

Old skool to the rescue… Xmodmap.

Edit (create if non-existent) your ~/.Xmodmap file as follows:

! Swap Caps_Lock and Escape.
! see man xmodmap

remove Lock = Caps_Lock
keycode 0×9 = Caps_Lock
keycode 0×42 = Escape
add Lock = Caps_Lock

And restart your X session. Bam. The above two issues are solved.

Comments

Disable T61p System Beep

My new T61p shipped with this awesome beep that would go off whenever the power state changed. Beep when it comes out of hibernation. Beep when you plug it in. Beep, beep beep beeeeppppp…. annoying & embarrassing.  I’ve been generally very pleased with my T61p, but seriously, how does a default setting like that get out the door?  And seriously, why did it take two months before I found the time to figure out how to change it?

Let’s turn it off!

  1. It’s a bios beep.  During startup press F1 to get into the bios ulitity (alternatively, press the ‘Blue ThinkVantage Button’ and then press F1 at the first menu.
  2. Config->Alerts and just disable them all.  No more beeps!
  3. Save and Exit.

Comments

Intel 4965AGN, T61p, and Debian

My new T61p has the standard built-in Intel 4965AGN wireless card for 802.11b/g/n goodness. The kernel has had driver support for this hardware since 2.6.24. But, after doing a default Debian Lenny install, the wireless just ain’t working… what gives?

Well, this comes up in /var/log/syslog and others:

iwl4965: iwlwifi-4965-1.ucode firmware file req failed: Reason -2
iwl4965: Could not read microcode: -2

As is explained here, the iwlwifi drivers require a binary firmware (aka microcode) image to function. The drivers themselves are free, both as in beer and as in freedom. However, the microcode images, in order to enforce end-user FCC compliance, are free as in beer but not freedom. Thus a default Debian install, which bends over backwards to be free as in beer and free as in freedom, does not include the microcode images.

Two options:

  1. Install the firmware image yourself. Find the image you need here (as of August 2008 the version you want was 1.21), download it, extract it, and copy it to /lib/firmware/iwlwifi-4965-1.ucode.
  2. Or, add the non-free repositories to your /etc/apt/sources.list, and do an apt-get install firmware-iwlwifi.

Or, pretend you didn’t really want wireless if you can’t have it free as in freedom… and put it on your to-do list to reverse-engineer that binary firmware image. Buena suerte! ;p

I can’t remember if a reboot was necessary after installing the microcode image. But that should be it in terms of edits and installs… everything wifi, all the way out to the gnome GUI, should now just automagically work.

Comments

Built-In Verizon EVDO on a T61p with Debian

This is the first in what will be a short series of posts of what I’ve had to do to get Debian (Lenny – currently the ‘testing’ distro) working fully and smoothly on my new T61p.

The key options in my T61p package:

39T4822 VBB WWAN
42V9332 SBB WAN:VERIZONSIERRACDMA2000
42V8603 SBB INT.WWAN ANTENNA 15.4″
42V8659 SBB CL.PLATE T61P WL WWAN
42W7002 SBB FCC-ID/LABEL FOR WWAN
42V8675 SBB VERIZON OPTION

That all translates to a slickly built-in Verizon card and antenna:

$ lsusb -v | grep Sierra
    Bus 006 Device 002: ID 1199:0220 Sierra Wireless, Inc.
    idVendor 0×1199 Sierra Wireless, Inc.
    iManufacturer 1 Sierra Wireless, Incorporated
    iProduct 2 Sierra Wireless MC5725 Modem

Here is the only officially unofficial official public documentation I could find for that card on Linux.

Before setting this up with Debian, I’d recommend getting it working with Windows if you haven’t reformatted over it yet. The card and connection pretty much ‘just works’ on Lenovo’s preinstalled Windows. This will mostly eliminate Verizon as the source of the problem if things don’t go right with Debian.

A default Debian install provides a number of tools you can use to configure and automate your connection. I like gnome-ppp (essentially a GUI frontend on wvdial) best. I’ve also set it up with gnome’s network-admin applet (System->Administration->Network), but it doesn’t provide good user feedback on the connection process or status. And by ‘good’, I mean ‘any’. Perhaps future versions will have better integration of dial-out connections, now that they’re coming back into style with EVDO and 3G networks. In any case, I will provide instructions for both these two tools here. (Note this is an either/or. There is no reason to bother setting this up with both tools, other than to test out the GUI’s.)

First, GUI configuration. Here’s your key points:

  • Username: YOURPHONENUMBER@vzw3g.com
  • Password: vzw
  • Phone number to dial: #777

For gnome-ppp, you want to:

  • Use the ‘Detect’ mechanism. It worked perfect for me. Try it.
  • Under Options, enable ’stupid mode’ to speed up the connection process substantially. You’re also calling Verizon stupid, in a extremely passive aggressive manner… ummm, feels so good…. stupid stupid stupid.

For network-admin:

  • Set the Modem port to /dev/ttyUSB0.
  • Check the ‘Set modem as default route to Internet’ option or your machine will just drop your outbound packets on the floor.
  • No remote authentication. In the file /etc/ppp/peers/ppp0, add a line ‘noauth’ to disable your authentication of the verizon servers. This means that if someone successfully hijacks Verizon’s ‘#777′ number, you will have no way of knowing, and they will have complete control over your traffic. (gnome-ppp does this ‘noauth’ for you automatically, for better or for worse.)
  • Do not set the modem volume. In the file /etc/chatscripts/ppp0, comment out the line that has a command like ‘AT&FH0XX’ where XX are wildcards depending on your GUI settings. Issuing this command causes the modem error out, reporting ‘NO CARRIER’ on the ensuing ATDT (dial) command.

And that’s it! For debugging, your friends are tail, /var/log/syslog, /var/log/messages, gnome-ppp’s GUI log display, cat, echo, /dev/ttyUSB0, minicom and or course, good old google.

Comments