summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorMarcel Ziswiler <marcel.ziswiler@toradex.com>2013-04-02 15:01:34 +0200
committerMarcel Ziswiler <marcel.ziswiler@toradex.com>2013-04-02 15:01:34 +0200
commit0fc73eb175a82dc11f6c1cc8e03f1d311d3180de (patch)
tree5e6010af6ff841ef70af551faa2d5df219990c3a /drivers
parentb7e54923eb384267f79ccaf4fcc1a3e28e88f2ed (diff)
input: touchscreen: android ics fusion_F0710A driver variant
For Android use ICS variant of Fusion 7 and 10 multi-touch driver (See Fusion 7 and 10 drivers for Linux.pdf and Linux Drivers Fusion 10.zip). Tested to be working both with Android 4.0.4 for Colibri T20 as well as Android 4.2.1 for Colibri T30.
Diffstat (limited to 'drivers')
-rw-r--r--drivers/input/touchscreen/fusion_F0710A.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/drivers/input/touchscreen/fusion_F0710A.c b/drivers/input/touchscreen/fusion_F0710A.c
index ac734abf5368..d29baf08de91 100644
--- a/drivers/input/touchscreen/fusion_F0710A.c
+++ b/drivers/input/touchscreen/fusion_F0710A.c
@@ -75,8 +75,12 @@ static int fusion_F0710A_register_input(void)
input_set_abs_params(dev, ABS_MT_POSITION_X, 0, fusion_F0710A.info.xres-1, 0, 0);
input_set_abs_params(dev, ABS_MT_POSITION_Y, 0, fusion_F0710A.info.yres-1, 0, 0);
+#ifdef CONFIG_ANDROID
+ input_set_abs_params(dev, ABS_MT_TRACKING_ID, 0, 15, 0, 0);
+#else
input_set_abs_params(dev, ABS_MT_TOUCH_MAJOR, 0, 255, 0, 0);
input_set_abs_params(dev, ABS_MT_WIDTH_MAJOR, 0, 15, 0, 0);
+#endif
ret = input_register_device(dev);
if (ret < 0)
@@ -220,6 +224,23 @@ static void fusion_F0710A_wq(struct work_struct *work)
}
}
+#ifdef CONFIG_ANDROID
+ if(z1)
+ {
+ input_report_abs(dev, ABS_MT_TRACKING_ID, 1);
+ input_report_abs(dev, ABS_MT_POSITION_X, x1);
+ input_report_abs(dev, ABS_MT_POSITION_Y, y1);
+ }
+ input_mt_sync(dev);
+
+ if(z2)
+ {
+ input_report_abs(dev, ABS_MT_TRACKING_ID, 2);
+ input_report_abs(dev, ABS_MT_POSITION_X, x2);
+ input_report_abs(dev, ABS_MT_POSITION_Y, y2);
+ }
+ input_mt_sync(dev);
+#else /* CONFIG_ANDROID */
input_report_abs(dev, ABS_MT_TOUCH_MAJOR, z1);
input_report_abs(dev, ABS_MT_WIDTH_MAJOR, 1);
input_report_abs(dev, ABS_MT_POSITION_X, x1);
@@ -230,6 +251,7 @@ static void fusion_F0710A_wq(struct work_struct *work)
input_report_abs(dev, ABS_MT_POSITION_X, x2);
input_report_abs(dev, ABS_MT_POSITION_Y, y2);
input_mt_sync(dev);
+#endif /* CONFIG_ANDROID */
input_sync(dev);