Technitribe

interesting problems (and a few solutions, too)

Technitribe
  • About the Authors
  • Log In
  • Log Out
  • Lost Password
  • Register
  • Reset Password
    • 20 Mar 2014

      Fedora 20 and the ThinkPad T440s touchpad

      Written by Tim Bielawa

      Background

      UPDATE 2014-10-17 – Installation of the “Insensitive Message Tray” extension has solved my issue with the notification bar frequently appearing when I did not want it to. This is on Gnome version 3.10.2. Note that pressing the Super+M keyboard shortcut will allow you to view the message tray when you want to.


      My old work laptop, the ThinkPad T510, went out of warranty a few months ago. At work this means I’m eligible for a hardware refresh with Best Monitors under 300, i.e., a new  laptop. Because they’re so much thinner and lighter, this time I decided to go with the 400 series. All in all it’s a fine piece of hardware, so long as you’re running Fedora 20 (or newer). I have two lingering issues however.

      1. The default touchpad configuration
      2. External display handling (which I won’t go into at this time)

      The T440s is one of those laptops trying it’s hardest to emulate the Apple Trackpad. That is to say, the T440S has one giant touchpad, no left/right/middle buttons. Unfortunately for Linux users, this is usually either a hit or a miss. It was a miss for me.

      My problems with laptop touchpads usually come down to a few basic things:

      • Unintentional taps/clicks
      • Random cursor movement due to palm/wrist bumping
      • Random page/document scrolling

      And specific to the T440s:

      • Extremely difficult to click without dragging
      • Difficult to find the right spot for middle clicking
      • (Most interestingly) Randomly causing the Gnome notification panel to appear

      In the past I’ve dealt with the former issues by simply disabling tap to click and touchpad scroll regions. But the T440s is an entirely different beast which required quite a bit more effort to make it usable.

      The Taming of the Shrew Touchpad

      Here’s how I was able to configure the ThinkPad T440s touchpad into something usable. I’ll break it down point by point so you can pick and choose which options you wish to apply.

      The first thing you need to know about is synaptics, the “touchpad input driver”. This comes from the xorg-x11-drv-synaptics package. Synaptics ships a command called synclient which allows you to tune the touchpad behavior without restarting your X server. You should have this package already installed if you’re running Fedora.

      Unintentional taps/clicks

      This is simple. Just disable Tap to click in the Mouse & Touchpad settings panel.

      Random Movement

      First, ensure that Disable while typing is checked in the Mouse & Touchpad settings panel.

      If that is insufficient (as in my case) then you can set the synaptics PalmDetect option to 1. This can be further tuned via the PalmMinWidth and PalmMinZ options, however, the defaults worked for me.

      Random Scrolling

      Same as the Random Movement problem.

      Clicking without Dragging

      This was the most frustrating issue with the T440s. The very act of pressing down on the touchpad to click causes the cursor to move. This makes it virtually impossible to click anything without your click target getting dragged around. We  can fix this with the HorizHysteresis and VertHysteresis options.

      • *Hysteresis – The minimum horizontal/vertical HW distance required to generate motion events. Default: 8

      The default hysteresis setting was insufficient for me. I changed both of mine to 30.

      Middle Clicking

      My specific issue here is that the middle-click region isn’t wide enough by default. This caused many unintentional left or right clicks.

      This was more challenging to figure out how to tune and required some Google-foo. Eventually I found myself on Peter Hutterer’s “Lenovo T440 touchpad button configuration” blog post. Peter’s intention in that blog post is to emulate having buttons at the top and bottom edges of the touchpad, rather than the entire touchpad behaving as a clickable region. We can borrow his work though and apply it to this issue. In the blog post he sets another synaptics option, SoftButtonAreas:

      • SoftButtonAreas=”60% 0 0 0 40% 60% 0 0″

      Setting Synaptics Options

      There are two methods available for setting synaptics options. The temporary solution is setting options via the synclient command (which I already referenced). The permanent solution is setting options via Xorg configuration files. Here’s an example of using the synclient command to set the HorizHysteresis and VertHysteresis options:

      • synclient HorizHysteresis=30 VertHysteresis=30

      Here is my 01-synaptics.conf file which sets all of these options permanently:

      • Tags »

    14 Comment on “Fedora 20 and the ThinkPad T440s touchpad”

    • Tom Callaway

      23 Mar 2014 08:03 pm

      Thanks for the excellent summary. In case you’re not already aware, updating the firmware on the DisplayPort firmware embedded in the 440s dock will resolve external display issues (all the ones I’ve ever had anyways). Unfortunately, I know of no way to do it except from Windows.

    • Tim Bielawa

      24 Mar 2014 07:03 am

      @tom, thanks for the comment.

      I’ve heard the same good (and bad) things about the dock. It’s a shame you can only update the firmware on a Windows box though 🙁

    • Jason Porter

      02 Apr 2014 11:04 am

      I don’t have the dock, and I’m only planning on one external monitor via the mini display port with an adapter. What sorts of problems should I expect to encounter? Can I update firmware from a VM?

    • Tim Bielawa

      02 Apr 2014 11:04 am

      Unfortunately no, you cannot flash the firmware from a VM. At this time the only method for flashing the dock firmware is having an actual laptop running Windows docked 🙁

    • RMON

      08 May 2014 02:05 am

      My laptop has a touchpad and I can configure that through the UI but I’ve a external keyboard with touchpad (Logitech K400), I can’t find a way to configure this, especisally the tap->click problem, any help?

    • andy

      17 Jun 2014 01:06 pm

      Hello,

      I’m really considering purchasing this laptop you have reviewed, and really appreciate the write up you made. I have two questions I can’t seem to find the answer to (in your post or elsewhere).

      I’m an ubuntu user, so I’m not sure if these commands will be the same for fedora, but I’m wondering what the maximum RAM the system will support (assuming in the future SoDIMM>8GB are available) and does hybrid suspend work?

      Could you run “sudo dmidecode -t 16” and send the output? This should say the maximum supported RAM.

      Could you test the command “pm-suspend-hybrid”? FYI, pm-suspend-hybrid basically does both a suspend and hibernate so that if your batter goes dead, you can still resume from a hibernate to disk, but if your batter doesn’t go dead, it will resume quicker (from a regular suspend) and just discard the data that was suspended to the disk.

      Thanks!

    • Tim Bielawa

      17 Jun 2014 01:06 pm

      Here’s a gist of the dmidecode:

      https://gist.github.com/tbielawa/df26260eaa408b5ca9d2

      I’ll reply back again after work when I have a chance to test pm-suspend-hybrid

    • Tim Bielawa

      19 Jun 2014 08:06 am

      Andy, just tested pm-suspend-hybrid and it worked perfectly for me.

      [root@deepfryer ~]# cat /etc/fedora-release
      Fedora release 20 (Heisenbug)
      [root@deepfryer ~]# uname -a
      Linux deepfryer.rdu.redhat.com 3.14.4-200.fc20.x86_64 #1 SMP Tue May 13 13:51:08 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux

    • andy

      19 Jun 2014 12:06 pm

      Interesting. Thank you for running these tests. Very much ashame of the RAM limitation with this machine, but other than that it looks pretty solid. Hybrid suspend is a pretty important one for me because if I place it in suspend and forget about it, without hybrid suspend, after the battery runs dead in a couple of days, it’s pretty much as if your computer crashed. Glad this feature appears to be working!

    • Tim Bielawa

      19 Jun 2014 12:06 pm

      Horay for working software!

    • Daniel

      30 Aug 2014 12:08 pm

      Tim, thank you for your insight into editing the drivers for the trackpad.
      I couldn’t find any settings that were adquate for me.

      I ended up remapping my left shift key to left mouse button, and the menu key to right mouse button. It makes life much, much easier to navigate around with the trackpoint. How I did it:

      1) find keycode of pressed key by commandline prog:
      2) enable key resetting
      3)remap key
      4) reset to default keylayout if you mess up
      Commands:

      xev
      xkbset m
      xmodmap -e “keycode 133 = Pointer_Button3”
      setxkbmap -layout us

      So those commands will remap the media button to right click for example. with the last command returning to default in case you write the wrong keycode in 🙂

    • Denis Medved

      11 Oct 2014 03:10 pm

      Thank you !
      Work fine for me !

      Thinkpad E440
      3.16.4-200.fc20.x86_64

    • Nick

      10 Jan 2015 12:01 am

      Hey Tim,
      Thanks a lot for your insight. I am a software developer and one thing I need the most is hibernating feature. I have always gone with Ubuntu up till this point but with T440s hibernation wasn’t working (creating numerous other issues) so I had to take a look at other distros.

      Now I have installed Fedora and it’s the same issue. giving pm-hibernate and pm-suspend-hybrid does nothing at all. The system just stays as nothing has happened. Only pm-suspend works but that doesn’t cut it for me.

      I was looking at http://fedoraproject.org/wiki/QA:Testcase_Power_Management_pm_hibernate and there they mention the file /sys/power/state. The content on my state are ‘freeze mem’. Any idea what this means and what should I need to consult to go from here?

      Thanks in advance

    • Tim Bielawa

      10 Jan 2015 03:01 pm

      Where to consult to go from here? Real quick I checked the kernel docs (kernel-doc package) in /usr/share/doc/kernel-doc-3.17.7/Documentation/power/states.txt and found some mentions of “freeze” and “mem”.

      If I were you I’d follow up by scanning over that file for more information. The good bits seemed to be right at the top.

      I’ve scp’d my states.txt file to http://lnx.cx/~tbielawa/states.txt so you can reference it quick. Keep in mind that’s for kernel-doc-3.17.7

    Leave a Reply Cancel reply

    Your email address will not be published. Required fields are marked *

    • The Authors
    • Virtual Disk Guide

      Interested in virtualization? Do QCOWs rule your filesystem? Are you a libvirt or KVM+QEMU wizard? I wrote a book about virtual disk management. Check out the The Linux Sysadmin's Guide to Virtual Disks online for free at ScribesGuides.com.


      Consider supporting the author by purchasing a hard copy of the first edition for just $10.00 on Lulu.com.

    • bitmath

      bitmath is a Python library for dealing with file size units (GiB's, kB's, etc) in a sane way. bitmath supports arithmetic, rich comparison, conversion, automatic best human-readable representation, and many other utility functions. Read some examples on the docs site or check out the source on GitHub.

    • latest posts

      • Querying block device sizes in Python on Linux and Mac OS X February 4, 2023
      • Using jq to filter an array of objects from JSON September 9, 2019
      • Two Year Break — And we’re back! November 16, 2018
    • tags

      bitmath blog conference css dblatex DNS DocBook eclipse Emacs Erlang Fedora fedora 22 filter GNU Screen Haiku Introduction java jboss LCSEE Linux locale locales fix slicehost ubuntu Macports module nist nXML-Mode opengl open source OS X package packaging pki prefix units presentation project pypi Python scholarship si summit Tutorial ubuntu xcode XML XMPP
    • h4ck teh world

      tbielawatbielawa
      • Issue Comment
        bitmath
        February 6, 2023 - 12:55 am UTC
      • Issue Comment
        bitmath
        February 6, 2023 - 12:54 am UTC
      • Push
        bitmath
        February 6, 2023 - 12:51 am UTC
      • Issue Comment
        bitmath
        February 6, 2023 - 12:36 am UTC
      • Push
        bitmath
        February 6, 2023 - 12:30 am UTC

Creative Commons License
Technitribe by Tim Bielawa is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.