You are not logged in.
Pages: 1
Hi,
I've an Elantech touchpad identified as this:
$lshal
udi = '/org/freedesktop/Hal/devices/pnp_ETD0001'
info.linux.driver = 'i8042 aux' (string)
info.parent = '/org/freedesktop/Hal/devices/computer' (string)
info.product = 'PnP Device (ETD0001)' (string)
info.subsystem = 'pnp' (string)
info.udi = '/org/freedesktop/Hal/devices/pnp_ETD0001' (string)
linux.hotplug_type = 2 (0x2) (int)
linux.subsystem = 'pnp' (string)
linux.sysfs_path = '/sys/devices/pnp0/00:05' (string)
pnp.id = 'ETD0001' (string)
It works but I cant figure out how to configure it.
I used the hal fdi config file as described in the wiki, but after hal restart (and also after reboot) the settings are not taken into account.
BTW the kcontrol touchpad settings management is not configurable (buttons are grey and no way to tick or click)
If someone has the same device and know about configuring it, please tell!!
Here ise the method I used :
$ sudo cp /usr/share/hal/fdi/policy/10osvendor/11-x11-synaptics.fdi /etc/hal/fdi/policy/
$ sudo nano /etc/hal/fdi/policy/11-x11-synaptics.fdi
// I tried to turn off two finger scrolling and event the whole touchpad
// <merge key="input.x11_options.touchpadoff" type="string">1</merge>
// <merge key="input.x11_options.VertTwoFingerScroll" type="string">false</merge>
// <merge key="input.x11_options.HorizTwoFingerScroll" type="string">true</merge>
$ sudo /etc/rc.d/hal restart
Nothing had changed in the touchpad config...
full file:
$ nano /etc/hal/fdi/policy/11-x11-synaptics.fdi
// nano
<?xml version="1.0" encoding="ISO-8859-1"?>
<deviceinfo version="0.2">
<device>
<match key="info.product" contains="ETPS/2 Elantech Touchpad">
<append key="info.capabilities" type="strlist">input.touchpad</append>
</match>
<match key="info.capabilities" contains="input.touchpad">
<merge key="input.x11_driver" type="string">synaptics</merge>
<merge key="input.x11_options.TapButton1" type="string">1</merge>
<merge key="input.x11_options.TapButton2" type="string">2</merge>
<merge key="input.x11_options.TapButton3" type="string">3</merge>
<!-- Arbitrary options can be passed to the driver using
the input.x11_options property since xorg-server-1.5. -->
<!-- EXAMPLES:
Switch on shared memory, enables the driver to be configured at runtime
<merge key="input.x11_options.SHMConfig" type="string">true</merge>
Maximum movement of the finger for detecting a tap
<merge key="input.x11_options.MaxTapMove" type="string">2000</merge>
Enable vertical scrolling when dragging along the right edge
<merge key="input.x11_options.VertEdgeScroll" type="string">true</merge>
Enable vertical scrolling when dragging with two fingers anywhere on the touchpad
<merge key="input.x11_options.VertTwoFingerScroll" type="string">false</merge>
Enable horizontal scrolling when dragging with two fingers anywhere on the touchpad
<merge key="input.x11_options.HorizTwoFingerScroll" type="string">true</merge>
If on, circular scrolling is used
<merge key="input.x11_options.CircularScrolling" type="string">true</merge>
<merge key="input.x11_options.touchpadoff" type="string">1</merge>
For other possible options, check CONFIGURATION DETAILS in synaptics man page
-->
</match>
</device>
</deviceinfo>
Last edited by florut (2010-02-20 14:02:54)
Using Chakra [core, community, extra, kdemod-core, kdemod-extragear, kdemod-playground, archlinuxfr]
ASUS UL30VT - Core2Duo SU7300 (x64) @1,3Ghz + GM45 Express (hybrid, GeForce G210M disabled)
Offline
[edit]
Last edited by florut (2010-02-20 14:01:55)
Using Chakra [core, community, extra, kdemod-core, kdemod-extragear, kdemod-playground, archlinuxfr]
ASUS UL30VT - Core2Duo SU7300 (x64) @1,3Ghz + GM45 Express (hybrid, GeForce G210M disabled)
Offline
[update!]
Using Chakra [core, community, extra, kdemod-core, kdemod-extragear, kdemod-playground, archlinuxfr]
ASUS UL30VT - Core2Duo SU7300 (x64) @1,3Ghz + GM45 Express (hybrid, GeForce G210M disabled)
Offline
I don't understand your last 2 posts !
Try putting this in your /etc/modprobe.d/modprobe.conf:
options psmouse proto=imps
and rebooting.
Mine started working correctly after I did that.
Offline
Try putting this in your /etc/modprobe.d/modprobe.conf:
options psmouse proto=imps
and rebooting.
Nope, no change at all with this option, my touchpad still doesnt take care about hal hotplugging configuration.
Thanks anyway...
I don't understand your last 2 posts !
They are meant to be deleted... I would like to!
Using Chakra [core, community, extra, kdemod-core, kdemod-extragear, kdemod-playground, archlinuxfr]
ASUS UL30VT - Core2Duo SU7300 (x64) @1,3Ghz + GM45 Express (hybrid, GeForce G210M disabled)
Offline
I'm with the same issue. Is your 2 finger tap (third button) working? Trying to figure out how to make mine works, I've tried the wiki but it doesn't seem right. If you enter "synclient -l", it prints your touchpad parameters, mine change when I modify the policy but the buttons doesn't work at all.
Offline
The question is how do you know 'PnP Device (ETD0001)' is really the Elantech touchpad ??
Apparently, the touchpad is erroneously recognized as "ImPS/2 Logitech Wheel Mouse". So if you want to make the "disable touchpad" extra key work, then you can add the following code to your /etc/acpi/handler.sh:
(this is in the same block of code for managing brightness)
hotkey)
event="$2"\ "$3"
case "$event" in
"ATKD 0000002"*)
acpi_fakekey 224
brightness=`echo $3 | sed 's/0000002//'`
setpci -s 00:02.0 F4.B=${brightness}f
;;
"ATKD 0000001"*)
acpi_fakekey 225
brightness=`echo $3 | sed 's/0000001//'`
setpci -s 00:02.0 F4.B=${brightness}f
;;
"ATKD 0000006b")
# get the id of the touchpad
XINPUTNUM=`xinput list 'ImPS/2 Logitech Wheel Mouse' | sed -n -e's/.*id=\([0-9]\+\).*/\1/p'`
# get the current state of the touchpad
TPSTATUS=`xinput list-props $XINPUTNUM | awk '/Device Enabled/ { print $NF }'`
# if getting the status failed, exit
test -z $TPSTATUS && exit 1
if [ $TPSTATUS = 0 ]; then
xinput set-prop $XINPUTNUM "Device Enabled" 1
else
xinput set-prop $XINPUTNUM "Device Enabled" 0
fi
;;
esac
;;
Make sure to restart acpid (/etc/rc.d/acpid restart). Now the touchpad is properly switch on/off with the corresponding extra key!
Offline
Hey torpe !
Seems you are the inexpected good man !
Thanks for the workaround...
Q: Is this single code supposed to solve brightness AND touchpad issues?
It works perfectly for the brightness buttons, but no way with the touchpad.
If you knew at least how to make it disable when mouse inserted, that would be great !
Well, thinks are going over now on UL30VT, I'll open a wiki page as soon as I get 15mins to do it !
The question is how do you know 'PnP Device (ETD0001)' is really the Elantech touchpad ??
The answer is that you are right, i'm not sure as it is wrongly recognized.
- Actually I saw it in the device properties using Seven
Last edited by florut (2010-05-15 15:56:49)
Using Chakra [core, community, extra, kdemod-core, kdemod-extragear, kdemod-playground, archlinuxfr]
ASUS UL30VT - Core2Duo SU7300 (x64) @1,3Ghz + GM45 Express (hybrid, GeForce G210M disabled)
Offline
I got the code for touchpad to work when I answered the thread, 3 days ago. and indeed, it is not working anymore... If I execute instructions step by step in a terminal, it is working though! I don't know exactly how to debug ACPI but I'll figure this out sometimes..
Concerning your question about deactivating the touchpad when an external mouse is plugged in, I guess we should put a script somewhere that would be used as a hook, but in which software (acpi, hal, udev?), I have no idea.. I'd say udev though.. Tell me if you find out something
Offline
I have som issues aswell. After every reboot or suspend I have to restart acpid to get the touchpad code to work. No errors in messages.log. I have no idea where to start debugging.
there's no place like ~/
Offline
It was tough but I eventually found how to really disable the touchpad. What was missing, was the code for identifying the X parameters. At the beginning of the /etc/acpi/handler.sh, you must copy the following code :
getXuser() {
user=`pinky| grep -m1 ":$displaynum " | awk '{print $1}'`
if [ x"$user" != x"" ]; then
userhome=`getent passwd $user | cut -d: -f6`
export XAUTHORITY=$userhome/.Xauthority
else
export XAUTHORITY=""
fi
}
getXconsole() {
console=`fgconsole`;
displaynum=`ps t tty$console | sed -n -re 's,.*/X .*:([0-9]+).*,\1,p'`
if [ x"$displaynum" != x"" ]; then
export DISPLAY=":$displaynum"
getXuser
fi
}
Then, you must call getXconsole at the beginning of the case condition (the one concerning the touchpad) :
...
"ATKD 0000006b")
logger "ACPI action: toggle touchpad"
getXconsole
# get the id of the touchpad
XINPUTNUM=`xinput list "ImPS/2 Logitech Wheel Mouse" | sed -n -e's/.*id=\([0-9]\+\).*/\1/p'`
...
Regarding the auto disabling of the touchpad when a mouse is plugged, I need more time to investigate, but udev definitely seems like the right candidate.
See this for example:
http://wiki.archlinux.org/index.php/Tou … _detection
Offline
So, last episode, how to disable the touchpad whenever a usb mouse is plugged..
First, create a file /etc/udev/rules.d/01-touchpad.rules in which you copy this:
ACTION=="add", SUBSYSTEM=="input", ENV{ID_INPUT_MOUSE}="1", ENV{ID_BUS}="usb", ENV{REMOVE_CMD}="/etc/udev/toggle_touchpad 1", RUN+="/etc/udev/toggle_touchpad 0"
Then, you create another file /etc/udev/toggle_touchpad in which you copy that:
#!/bin/sh
getXuser() {
user=`pinky| grep -m1 ":$displaynum " | awk '{print $1}'`
if [ x"$user" != x"" ]; then
userhome=`getent passwd $user | cut -d: -f6`
export XAUTHORITY=$userhome/.Xauthority
else
export XAUTHORITY=""
fi
}
getXconsole() {
console=`fgconsole`;
displaynum=`ps t tty$console | sed -n -re 's,.*/X .*:([0-9]+).*,\1,p'`
if [ x"$displaynum" != x"" ]; then
export DISPLAY=":$displaynum"
getXuser
fi
}
if [ $# -lt 1 ]; then
exit
elif [ "$1" -eq "0" ]; then
enable=0
else
enable=1
fi
getXconsole
# get the id of the touchpad
XINPUTNUM=`xinput list "ImPS/2 Logitech Wheel Mouse" | sed -n -e's/.*id=\([0-9]\+\).*/\1/p'`
# get the current state of the touchpad
TPSTATUS=`xinput list-props $XINPUTNUM | awk '/Device Enabled/ { print $NF }'`
# if getting the status failed, exit
test -z $TPSTATUS && exit 1
xinput set-prop $XINPUTNUM "Device Enabled" $enable
Be sure to make this last file executable.
You may need to reload rules in udev (udevadm --reload-rules).
Enjoy
Offline
Great work, torpe23!
But there must be something different with the pinky output on my system than on yours.
The getXuser() function isn't able to get the username. It greps for :0 in the pinky output, which isn't there:
$ pinky
Login Name TTY Idle When Where
oew *tty1 00:25 2010-05-23 23:54
Since I'm the only one using my laptop i got it to work by grepping for my username, which is a ugly hack
What does your pinky output look like?
edit: btw, this is for /etc/acpi/handler.sh not udev rules, if that changes anything
Last edited by oew (2010-05-23 22:24:58)
there's no place like ~/
Offline
oew,
here is pinky's output on my computer:
$ pinky
Login Name TTY Idle When Where
joel ?:0 ????? 2010-05-24 21:54
joel pts/0 00:42 2010-05-24 21:54 :0
Offline
The kernel, or whatever is in charge of this, is not reporting the touchpad as "ImPS/2 Logitech Wheel Mouse" anymore, but as "ETPS/2 Elantech Touchpad" now. So you need to change the line containing 'xinput list "..." | sed ...' with the new name for the touchpad disabling to work properly.
Offline
#!/bin/sh
# Default acpi script that takes an entry for all actions
# NOTE: This is a 2.6-centric script. If you use 2.4.x, you'll have to
# modify it to not use /sys
minspeed=`cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_min_freq`
maxspeed=`cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_max_freq`
setspeed="/sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed"
set $*
getXuser() {
user=`pinky| grep -m1 ":$displaynum " | awk '{print $1}'`
if [ x"$user" != x"" ]; then
userhome=`getent passwd $user | cut -d: -f6`
export XAUTHORITY=$userhome/.Xauthority
else
export XAUTHORITY=""
fi
}
getXconsole() {
console=`fgconsole`;
displaynum=`ps t tty$console | sed -n -re 's,.*/X .*:([0-9]+).*,\1,p'`
if [ x"$displaynum" != x"" ]; then
export DISPLAY=":$displaynum"
getXuser
fi
}
case "$1" in
button/power)
#echo "PowerButton pressed!">/dev/tty5
case "$2" in
PWRF) logger "PowerButton pressed: $2" ;;
*) logger "ACPI action undefined: $2" ;;
esac
;;
button/sleep)
case "$2" in
SLPB) echo -n mem >/sys/power/state ;;
*) logger "ACPI action undefined: $2" ;;
esac
;;
ac_adapter)
case "$2" in
AC)
case "$4" in
00000000)
echo -n $minspeed >$setspeed
#/etc/laptop-mode/laptop-mode start
;;
00000001)
echo -n $maxspeed >$setspeed
#/etc/laptop-mode/laptop-mode stop
;;
esac
;;
*) logger "ACPI action undefined: $2" ;;
esac
;;
battery)
case "$2" in
BAT0)
case "$4" in
00000000) #echo "offline" >/dev/tty5
;;
00000001) #echo "online" >/dev/tty5
;;
esac
;;
CPU0)
;;
*) logger "ACPI action undefined: $2" ;;
esac
;;
button/lid)
#echo "LID switched!">/dev/tty5
;;
hotkey)
event="$2"\ "$3"
case "$event" in
"ATKD 0000002"*)
acpi_fakekey 224
brightness=`echo $3 | sed 's/0000002//'`
setpci -s 00:02.0 F4.B=${brightness}f
/home/dominik/bin/brightness.sh $brightness &
;;
"ATKD 0000001"*)
acpi_fakekey 225
brightness=`echo $3 | sed 's/0000001//'`
setpci -s 00:02.0 F4.B=${brightness}f
/home/dominik/bin/brightness.sh $brightness &
;;
"ATKD 0000006b")
logger "ACPI action: toggle touchpad"
getXconsole
# get the id of the touchpad
XINPUTNUM=`xinput list "ETPS/2 Elantech Touchpad" | sed -n -e's/.*id=\([0-9]\+\).*/\1/p'`
# get the current state of the touchpad
TPSTATUS=`xinput list-props $XINPUTNUM | awk '/Device Enabled/ { print $NF }'`
echo $XINPUTNUM > /home/dominik/test
# if getting the status failed, exit
test -z $TPSTATUS && exit 1
if [ $TPSTATUS = 0 ]; then
xinput set-prop $XINPUTNUM "Device Enabled" 1
else
xinput set-prop $XINPUTNUM "Device Enabled" 0
fi
;;
esac
;;
*)
logger "ACPI group/action undefined: $1 / $2"
;;
esac
Well, it doesn't work anymore. Running the commands which determine the value of XINPUTNUM and TPSTATUS works just perfect, which leads me to think that getXconsole is broken...
EDIT
getXconsole() {
console=`fgconsole`;
displaynum=`ps t tty$console | sed -n -re 's,.*/X .*:([0-9]+).*,\1,p'`
if [ x"$displaynum" != x"" ]; then
export DISPLAY=":$displaynum"
getXuser
fi
}
was the culprit. " tty$console" should be " tty $console".
Last edited by Arthenik (2010-10-14 16:29:03)
Offline
Pages: 1