[oe-commits] Martin Jansa : Xorg better usb mouse check, add ts_calibration also to Xsession, ie for running Xorg after install without reboot

git version control git at git.openembedded.org
Fri Sep 25 08:22:34 UTC 2009


Module: openembedded.git
Branch: shr/import
Commit: eac738aa2a06e71ec6429d27d70b717a0f27819d
URL:    http://gitweb.openembedded.net/?p=openembedded.git&a=commit;h=eac738aa2a06e71ec6429d27d70b717a0f27819d

Author: Martin Jansa <martin.jansa at gmail.com>
Date:   Thu Sep 24 17:05:14 2009 +0000

Xorg better usb mouse check, add ts_calibration also to Xsession, ie for running Xorg after install without reboot

Signed-off-by: Klaus Kurzmann <mok at fluxnetz.de>

---

 .../xserver-kdrive-common/shr/30xTs_Calibrate      |   16 ++++++++++++++++
 .../xserver-kdrive-common/shr/Xserver              |   11 +++++------
 .../xserver-kdrive-common_0.1.bb                   |    2 +-
 3 files changed, 22 insertions(+), 7 deletions(-)

diff --git a/recipes/xserver-kdrive-common/xserver-kdrive-common/shr/30xTs_Calibrate b/recipes/xserver-kdrive-common/xserver-kdrive-common/shr/30xTs_Calibrate
new file mode 100644
index 0000000..32375d7
--- /dev/null
+++ b/recipes/xserver-kdrive-common/xserver-kdrive-common/shr/30xTs_Calibrate
@@ -0,0 +1,16 @@
+#!/bin/sh
+
+while [ ! -z $TSLIB_TSDEVICE ] && [ ! -f /etc/pointercal ]
+do
+   /usr/bin/xtscal
+done
+
+if [ -d /sys/bus/i2c/devices/0-0073/s3c2440-ts/calibration/ ]; then
+  echo 0 > /sys/bus/i2c/devices/0-0073/s3c2440-ts/calibration/0
+  echo 80000 > /sys/bus/i2c/devices/0-0073/s3c2440-ts/calibration/1
+  echo -8000000 > /sys/bus/i2c/devices/0-0073/s3c2440-ts/calibration/2
+  echo -81000 > /sys/bus/i2c/devices/0-0073/s3c2440-ts/calibration/3
+  echo 0 > /sys/bus/i2c/devices/0-0073/s3c2440-ts/calibration/4
+  echo 75000000 > /sys/bus/i2c/devices/0-0073/s3c2440-ts/calibration/5
+  echo 65536 > /sys/bus/i2c/devices/0-0073/s3c2440-ts/calibration/6
+fi
diff --git a/recipes/xserver-kdrive-common/xserver-kdrive-common/shr/Xserver b/recipes/xserver-kdrive-common/xserver-kdrive-common/shr/Xserver
index ba939a6..35a93ca 100644
--- a/recipes/xserver-kdrive-common/xserver-kdrive-common/shr/Xserver
+++ b/recipes/xserver-kdrive-common/xserver-kdrive-common/shr/Xserver
@@ -54,12 +54,11 @@ if [ -z "$TSLIB_TSDEVICE" ] && [ -e /dev/touchscreen/ucb1x00 ]; then
 fi
 
 # use usb mouse if present
-# Xorg doesn't support "-mouse" option, and uses /dev/input/mice automatically
-if [ -z "$TSLIB_TSDEVICE" ] && [ -e /dev/input/mice ] && [ "$XSERVER" != "/usr/bin/Xorg" ]; then
-  ARGS="$ARGS -mouse /dev/input/mice"
-  #/dev/input/mice exists on neo even without usb mouse connected
-  #create better test for usb mouse and uncomment following line
-  #USB_MOUSE="1"
+# Xorg doesn't support "-mouse" option, and uses /dev/input/mouse0 automatically
+# On neo we have touchscreen as /dev/input/mice, usb connected mouse would be probably mouse0
+if [ -z "$TSLIB_TSDEVICE" ] && [ -e /dev/input/mouse0 ] && [ "$XSERVER" != "/usr/bin/Xorg" ]; then
+  ARGS="$ARGS -mouse /dev/input/mouse0"
+  USB_MOUSE="1"
 fi
 
 # start off server in conventional location.
diff --git a/recipes/xserver-kdrive-common/xserver-kdrive-common_0.1.bb b/recipes/xserver-kdrive-common/xserver-kdrive-common_0.1.bb
index 33c0a40..d570666 100644
--- a/recipes/xserver-kdrive-common/xserver-kdrive-common_0.1.bb
+++ b/recipes/xserver-kdrive-common/xserver-kdrive-common_0.1.bb
@@ -1,7 +1,7 @@
 DESCRIPTION = "Common X11 scripts"
 LICENSE = "GPL"
 SECTION = "x11"
-PR = "r38"
+PR = "r40"
 
 SRC_URI = "\
   file://Xdefaults \





More information about the Openembedded-commits mailing list