While suspended this laptop uses about 1% per hour of battery charge so we need hibernation, which is disabled by default in Ubuntu 12.04/Mint 13, so I had to enable it. Google search shows how to do it, it requires some tinkering, and to enable/create a swap partition. Hibernation works VERY well on this machine.
The next item is disabling the Touchpad when an external mouse is inserted. Two steps:
Create “/etc/udev/rules.d/72-touchpad.rules”.
Code:
# /etc/udev/rules.d/72-touchpad.rules
#
# Enables/Disables SynPS/2 Synaptics TouchPad upon external mouse detection.
# Works on insertion/removal of external mouse and on resume from suspend or hibernation.
# Note $USER variable
ACTION=="add", SUBSYSTEM=="input", KERNEL=="mouse[0-9]", ENV{DISPLAY}=":0", ENV{XAUTHORITY}="/home/$USER/.Xauthority", ENV{ID_CLASS}="mouse", ENV{REMOVE_CMD}="/usr/bin/synclient TouchpadOff=0", RUN+="/usr/bin/synclient TouchpadOff=1"
Create “/usr/local/bin/toggle-touchpad.sh” and add it to your Startup Applications:
Code:
#!/bin/bash
# /usr/local/bin/toggle-touchpad.sh
# PURPOSE:
# Disables the TouchPad if a second (external) mouse is available, otherwise enables the TouchPad.
# INSTRUCTIONS:
# If laptop has a Fn+ shortcut key to enable/disable the TouchPad, it should be left in the
# enabled state otherwise this script will be ineffective.
if [ `ls -d /dev/input/mouse* | wc -l` -gt 1 ]; then
# disable touchpad if more than one mouse is available
/usr/bin/synclient TouchpadOff=1
else
# enable touchpad if only one mouse is available
/usr/bin/synclient TouchpadOff=0
fi
Bookmarks