|
Posted at 7/20/2015 17:48:08
Only Author
2#
1 Add touch screen support to FirePrime Linux
=============================================
1.1 Introduction
~~~~~~~~~~~~~~~~
X11 window system uses evdev input driver to handle touch screen
events. There're mainly two steps to add touch screen support:
1. Add X11 configuration file to use evdev driver for touch screen.
2. Make evdev support touch screen (also emulate right mouse button).
1.2 Configuration
~~~~~~~~~~~~~~~~~
Create file `/etc/X11/xorg.conf.d/10-evdev-gslX680.conf' with
following contents:
,----
| Section "InputClass"
| Identifier "gslX680 evdev touchscreen"
| MatchProduct "gslX680"
| MatchDevicePath "/dev/input/event*"
| Option "EmulateThirdButton" "true"
| Option "EmulateThirdButtonTimeout" "500"
| Option "EmulateThirdButtonMoveThreshold" "50"
| Driver "evdev"
| EndSection
`----
1.3 Make evdev support touch screen
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The original evdev driver does not support Android input touch driver
well. It needs some patches.
Here're the main steps to patch and recompile a new one.
1.3.1 Install build environment and dependencies
------------------------------------------------
,----
| sudo apt-get install build-essentials
| sudo apt-get build-dep xserver-xorg-input-evdev
`----
1.3.2 Fetch, patch, and compile the source code
-----------------------------------------------
,----
| sudo apt-get source xserver-xorg-input-evdev
| cd xserver-xorg-input-evdev-2.9.0/src
| GITHUB=https://github.com/TeeFirefly/xf86-input-evdev/tree/ba37709e2aab50354c9925ca1e975779a16c67dc
| wget $GITHUB/src/emuThird.c
| wget $GITHUB/src/evdev.c
| wget $GITHUB/src/evdev.h
| cd ..
| make -j4
`----
1.3.3 Install the newly built module
------------------------------------
,----
| mv /usr/lib/xorg/modules/input/evdev_drv.so /usr/lib/xorg/modules/input/evdev_drv.so.orig
| cp src/.libs/evdev_drv.so /usr/lib/xorg/modules/input/evdev_drv.so
`----
Restart system to take effect
|
|