diff options
author | Michael Gebetsroither <michael@mgeb.org> | 2011-11-05 02:56:05 -0400 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2011-11-05 03:02:27 -0400 |
commit | d2cc817a7697685f034c90542053d85e7012c760 (patch) | |
tree | bb3d97d0bc4e5d0124181b6e9f73ebc7fe46e37f /drivers | |
parent | 1729ad1f4f9e167ade84ca8b5269695c42351160 (diff) |
Input: usbtouchscreen - add ELO IntelliTouch 2700 support
Signed-off-by: Michael Gebetsroither <michael@mgeb.org>
Reviewed-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/input/touchscreen/Kconfig | 6 | ||||
-rw-r--r-- | drivers/input/touchscreen/usbtouchscreen.c | 36 |
2 files changed, 42 insertions, 0 deletions
diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig index 3488ffe1fa0a..3c986cf48904 100644 --- a/drivers/input/touchscreen/Kconfig +++ b/drivers/input/touchscreen/Kconfig | |||
@@ -541,6 +541,7 @@ config TOUCHSCREEN_USB_COMPOSITE | |||
541 | - GoTop Super_Q2/GogoPen/PenPower tablets | 541 | - GoTop Super_Q2/GogoPen/PenPower tablets |
542 | - JASTEC USB Touch Controller/DigiTech DTR-02U | 542 | - JASTEC USB Touch Controller/DigiTech DTR-02U |
543 | - Zytronic controllers | 543 | - Zytronic controllers |
544 | - Elo TouchSystems 2700 IntelliTouch | ||
544 | 545 | ||
545 | Have a look at <http://linux.chapter7.ch/touchkit/> for | 546 | Have a look at <http://linux.chapter7.ch/touchkit/> for |
546 | a usage description and the required user-space stuff. | 547 | a usage description and the required user-space stuff. |
@@ -620,6 +621,11 @@ config TOUCHSCREEN_USB_JASTEC | |||
620 | bool "JASTEC/DigiTech DTR-02U USB touch controller device support" if EXPERT | 621 | bool "JASTEC/DigiTech DTR-02U USB touch controller device support" if EXPERT |
621 | depends on TOUCHSCREEN_USB_COMPOSITE | 622 | depends on TOUCHSCREEN_USB_COMPOSITE |
622 | 623 | ||
624 | config TOUCHSCREEN_USB_ELO | ||
625 | default y | ||
626 | bool "Elo TouchSystems 2700 IntelliTouch controller device support" if EXPERT | ||
627 | depends on TOUCHSCREEN_USB_COMPOSITE | ||
628 | |||
623 | config TOUCHSCREEN_USB_E2I | 629 | config TOUCHSCREEN_USB_E2I |
624 | default y | 630 | default y |
625 | bool "e2i Touchscreen controller (e.g. from Mimo 740)" | 631 | bool "e2i Touchscreen controller (e.g. from Mimo 740)" |
diff --git a/drivers/input/touchscreen/usbtouchscreen.c b/drivers/input/touchscreen/usbtouchscreen.c index 73fd6642b681..9dbd8b4d9a6e 100644 --- a/drivers/input/touchscreen/usbtouchscreen.c +++ b/drivers/input/touchscreen/usbtouchscreen.c | |||
@@ -16,6 +16,7 @@ | |||
16 | * - JASTEC USB touch controller/DigiTech DTR-02U | 16 | * - JASTEC USB touch controller/DigiTech DTR-02U |
17 | * - Zytronic capacitive touchscreen | 17 | * - Zytronic capacitive touchscreen |
18 | * - NEXIO/iNexio | 18 | * - NEXIO/iNexio |
19 | * - Elo TouchSystems 2700 IntelliTouch | ||
19 | * | 20 | * |
20 | * Copyright (C) 2004-2007 by Daniel Ritz <daniel.ritz@gmx.ch> | 21 | * Copyright (C) 2004-2007 by Daniel Ritz <daniel.ritz@gmx.ch> |
21 | * Copyright (C) by Todd E. Johnson (mtouchusb.c) | 22 | * Copyright (C) by Todd E. Johnson (mtouchusb.c) |
@@ -138,6 +139,7 @@ enum { | |||
138 | DEVTYPE_ZYTRONIC, | 139 | DEVTYPE_ZYTRONIC, |
139 | DEVTYPE_TC45USB, | 140 | DEVTYPE_TC45USB, |
140 | DEVTYPE_NEXIO, | 141 | DEVTYPE_NEXIO, |
142 | DEVTYPE_ELO, | ||
141 | }; | 143 | }; |
142 | 144 | ||
143 | #define USB_DEVICE_HID_CLASS(vend, prod) \ | 145 | #define USB_DEVICE_HID_CLASS(vend, prod) \ |
@@ -239,6 +241,10 @@ static const struct usb_device_id usbtouch_devices[] = { | |||
239 | .driver_info = DEVTYPE_NEXIO}, | 241 | .driver_info = DEVTYPE_NEXIO}, |
240 | #endif | 242 | #endif |
241 | 243 | ||
244 | #ifdef CONFIG_TOUCHSCREEN_USB_ELO | ||
245 | {USB_DEVICE(0x04e7, 0x0020), .driver_info = DEVTYPE_ELO}, | ||
246 | #endif | ||
247 | |||
242 | {} | 248 | {} |
243 | }; | 249 | }; |
244 | 250 | ||
@@ -945,6 +951,24 @@ static int nexio_read_data(struct usbtouch_usb *usbtouch, unsigned char *pkt) | |||
945 | 951 | ||
946 | 952 | ||
947 | /***************************************************************************** | 953 | /***************************************************************************** |
954 | * ELO part | ||
955 | */ | ||
956 | |||
957 | #ifdef CONFIG_TOUCHSCREEN_USB_ELO | ||
958 | |||
959 | static int elo_read_data(struct usbtouch_usb *dev, unsigned char *pkt) | ||
960 | { | ||
961 | dev->x = (pkt[3] << 8) | pkt[2]; | ||
962 | dev->y = (pkt[5] << 8) | pkt[4]; | ||
963 | dev->touch = pkt[6] > 0; | ||
964 | dev->press = pkt[6]; | ||
965 | |||
966 | return 1; | ||
967 | } | ||
968 | #endif | ||
969 | |||
970 | |||
971 | /***************************************************************************** | ||
948 | * the different device descriptors | 972 | * the different device descriptors |
949 | */ | 973 | */ |
950 | #ifdef MULTI_PACKET | 974 | #ifdef MULTI_PACKET |
@@ -953,6 +977,18 @@ static void usbtouch_process_multi(struct usbtouch_usb *usbtouch, | |||
953 | #endif | 977 | #endif |
954 | 978 | ||
955 | static struct usbtouch_device_info usbtouch_dev_info[] = { | 979 | static struct usbtouch_device_info usbtouch_dev_info[] = { |
980 | #ifdef CONFIG_TOUCHSCREEN_USB_ELO | ||
981 | [DEVTYPE_ELO] = { | ||
982 | .min_xc = 0x0, | ||
983 | .max_xc = 0x0fff, | ||
984 | .min_yc = 0x0, | ||
985 | .max_yc = 0x0fff, | ||
986 | .max_press = 0xff, | ||
987 | .rept_size = 8, | ||
988 | .read_data = elo_read_data, | ||
989 | }, | ||
990 | #endif | ||
991 | |||
956 | #ifdef CONFIG_TOUCHSCREEN_USB_EGALAX | 992 | #ifdef CONFIG_TOUCHSCREEN_USB_EGALAX |
957 | [DEVTYPE_EGALAX] = { | 993 | [DEVTYPE_EGALAX] = { |
958 | .min_xc = 0x0, | 994 | .min_xc = 0x0, |