Commit graph

14 commits

Author SHA1 Message Date
Peter Hutterer
2e41b6778b tools: specify width by height in the edge-detector help
Fixes #13

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2020-05-07 07:56:57 +10:00
Peter Hutterer
521edcba27 tools: rename the example device in the touchpad-edge-detector
In the hope that people don't blindly type event0 from now on.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2020-04-28 07:15:53 +10:00
Peter Hutterer
223909ed0b tools: fix the include path for local includes
Make sure we use the local include files, and correct the path accordingly.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2020-02-17 17:42:32 +10:00
Peter Hutterer
0a66de813e tools: drop use of HAVE_CONFIG_H
There's no case where we don't have a config.h

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2020-02-14 12:03:23 +10:00
Peter Hutterer
2a612997ab tools: fix kernel-announced width/height
Side-effect of 240ba34ebd was that "touchpad size as listed by the kernel"
was now dependent on the values we got. This one is a static one based on the
axis info.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2016-09-15 11:57:52 +10:00
Peter Hutterer
240ba34ebd tools: fix the touchpad resolution calculation
Previous ones used the absinfo from the kernel but since we never updated that
from within the tool, the output was always the same.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2016-08-26 11:43:54 +10:00
Peter Hutterer
761687e995 tools: require a minimum size for touchpads
This mostly aims to catch users trying to specify the size in inches.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2016-08-01 07:47:46 +10:00
Peter Hutterer
911106230a tools: change touchpad-edge-detector to require physical size
Almost no-one does the calculations for me to update the udev rules (and some
rules were submitted with the <x resolution> placeholders left in).
Require the user to specify the physical size so we just copy/paste the actual
udev rule.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Acked-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
2016-08-01 06:48:04 +10:00
Peter Hutterer
33d51dbaa4 tools: fix touchpad-edge-detector udev rule output
off-by-one error on the ABS_ axes printed. ABS_X/Y are 0 and 1.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2015-11-10 13:07:10 +10:00
Peter Hutterer
fa3c5622de tools: print out evdev override udev rule from touchpad edge detector
We're starting to collect overrides for custom devices, making this easier for
users and saves us time. Once we measured everything, print out a
guesstimated udev rule and instructions on how to calculate the resolution.
Extra output now is:

	Touchpad size as listed by the kernel: 132x111mm
	Calculate resolution as:
		x axis: 6076/<width in mm>
		y axis: 5021/<height in mm>

	Suggested udev rule:
	# <Laptop model description goes here>
	evdev:input:b0005v05ACp030E*
	 EVDEV_ABS_01=-2694:2862:<x resolution>
	 EVDEV_ABS_02=-20:121:<y resolution>
	 EVDEV_ABS_35=-2694:2862:<x resolution>
	 EVDEV_ABS_36=-20:121:<y resolution>

The ABS_MT_ axes are only printed if the device have them, if the device isn't
bluetooth/usb we print the dmi modalias instead.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2015-08-24 08:16:09 +10:00
Peter Hutterer
f54656ecc1 tools: complain about devices that don't have abs x/y axes in the edge detector
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2015-06-10 14:53:40 +10:00
Peter Hutterer
4160d94baf cosmetic: fix a couple of duplicate/missing empty lines
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2015-03-04 08:41:33 +10:00
Emmanuele Bassi
84d2d5034c tools: Fix compiler warning
Signed-off-by: Emmanuele Bassi <ebassi@gnome.org>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2014-02-26 07:24:46 +10:00
Peter Hutterer
5250243b6f tools: add a tool to print the actual range provided by a touchpad
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2014-02-25 13:18:18 +10:00