Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have recently installed Ubuntu (and its derivatives Xubuntu and Kubuntu) on my laptop.

On my computer, I have both a touchpad and a trackpoint. In Windows, the touchpad is disabled when I use the trackpoint.

Is there any way to recreate this in Linux?

share|improve this question
Check out this site – Raystafarian Feb 9 '12 at 19:24

I Googled and Googled for a fix for this exact problem and this is what I came up with to suit my system:

#Change /dev/input/event13 to your trackstick event
    cat /dev/input/event13 > /tmp/mousemove &
#initialize counter to prevent garbage file from growing
    while true ; do 
        newchecksum=`md5sum /tmp/mousemove | awk '{print $1}'`
        #see if trackpad is already disabled
        if [ "$trackpad" = "off" ]; then

            #compare previous checksum to current if they're same trackstick is not moving
            if [ "$oldchecksum" = "$newchecksum" ]; then
                #make sure trackpad is enabled
                xinput set-prop "SynPS/2 Synaptics TouchPad" "Device Enabled" 1;


            #compare previous checksum to current if they're different trackstick is moving
            if [ "$oldchecksum" != "$newchecksum" ]; then
                #disable trackpad
                xinput set-prop "SynPS/2 Synaptics TouchPad" "Device Enabled" 0;


        #check for count to keep poll file smaller
        if [ "$i" = "300" ]; then
            echo '' > /tmp/mousemove;
            newchecksum=`md5sum /tmp/mousemove | awk '{print $1}'`
            #sleep for 1 second so we don't eat up resources
            #if the update speed is not fast enough for you a smaller number such as .75 may be better
            sleep 1;

Since I run fluxbox on arch I added the script call in my ~/.fluxbox/apps

Only caveat I could find was that if you manage to pkill cat as root, which this script must be run as to access the mouse event, you’ll kill the script, at the same time if you kill the script and don’t kill cat it will continue to run until you either run out of space in /tmp, pkill cat, or reboot the system.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .