From fa21fd3489b709391775b1a3a6889b433a3a5c60 Mon Sep 17 00:00:00 2001 From: Ondrej Zary Date: Tue, 3 Jul 2007 01:55:03 -0400 Subject: [PATCH] --- yaml --- r: 58495 b: refs/heads/master c: df561fcd445c9cf9f4fff98ea795a0e72b7dc1e1 h: refs/heads/master i: 58493: ecfa8c61c5b71a3927fbe7e67fc84c275b7ed452 58491: c6bc44b7d33801fe201ee7b20ea2513829914ffa 58487: 1bc05111bab3672d0846c4880fd838bbf353003b 58479: b87e9ffecc058de63032619b394a7cb8c14f01bb 58463: 523ffa7fed89602b4004374e209dbb23913cf0c3 58431: 187378e6b65ffd9217f43c2d78a890b232fe7d64 58367: a5b04528605a7cb28a2e6496f0dbd6171d63317f v: v3 --- [refs] | 2 +- trunk/drivers/input/touchscreen/Kconfig | 6 ++++ .../input/touchscreen/usbtouchscreen.c | 33 +++++++++++++++++++ 3 files changed, 40 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index 5caae5e0ffc1..3233ddc7e2fd 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 1e2831db01c0726ec046e69719a10d7696b283fb +refs/heads/master: df561fcd445c9cf9f4fff98ea795a0e72b7dc1e1 diff --git a/trunk/drivers/input/touchscreen/Kconfig b/trunk/drivers/input/touchscreen/Kconfig index e5cca9bd0406..69371779806a 100644 --- a/trunk/drivers/input/touchscreen/Kconfig +++ b/trunk/drivers/input/touchscreen/Kconfig @@ -177,6 +177,7 @@ config TOUCHSCREEN_USB_COMPOSITE - some other eTurboTouch - Gunze AHL61 - DMC TSC-10/25 + - IRTOUCHSYSTEMS/UNITOP Have a look at for a usage description and the required user-space stuff. @@ -219,4 +220,9 @@ config TOUCHSCREEN_USB_DMC_TSC10 bool "DMC TSC-10/25 device support" if EMBEDDED depends on TOUCHSCREEN_USB_COMPOSITE +config TOUCHSCREEN_USB_IRTOUCH + default y + bool "IRTOUCHSYSTEMS/UNITOP device support" if EMBEDDED + depends on TOUCHSCREEN_USB_COMPOSITE + endif diff --git a/trunk/drivers/input/touchscreen/usbtouchscreen.c b/trunk/drivers/input/touchscreen/usbtouchscreen.c index e3f22852bd09..b407028ffc59 100644 --- a/trunk/drivers/input/touchscreen/usbtouchscreen.c +++ b/trunk/drivers/input/touchscreen/usbtouchscreen.c @@ -9,6 +9,7 @@ * - eTurboTouch * - Gunze AHL61 * - DMC TSC-10/25 + * - IRTOUCHSYSTEMS/UNITOP * * Copyright (C) 2004-2006 by Daniel Ritz * Copyright (C) by Todd E. Johnson (mtouchusb.c) @@ -110,6 +111,7 @@ enum { DEVTYPE_ETURBO, DEVTYPE_GUNZE, DEVTYPE_DMC_TSC10, + DEVTYPE_IRTOUCH, }; static struct usb_device_id usbtouch_devices[] = { @@ -150,6 +152,11 @@ static struct usb_device_id usbtouch_devices[] = { {USB_DEVICE(0x0afa, 0x03e8), .driver_info = DEVTYPE_DMC_TSC10}, #endif +#ifdef CONFIG_TOUCHSCREEN_USB_IRTOUCH + {USB_DEVICE(0x595a, 0x0001), .driver_info = DEVTYPE_IRTOUCH}, + {USB_DEVICE(0x6615, 0x0001), .driver_info = DEVTYPE_IRTOUCH}, +#endif + {} }; @@ -415,6 +422,21 @@ static int dmc_tsc10_read_data(struct usbtouch_usb *dev, unsigned char *pkt) #endif +/***************************************************************************** + * IRTOUCH Part + */ +#ifdef CONFIG_TOUCHSCREEN_USB_IRTOUCH +static int irtouch_read_data(struct usbtouch_usb *dev, unsigned char *pkt) +{ + dev->x = (pkt[3] << 8) | pkt[2]; + dev->y = (pkt[5] << 8) | pkt[4]; + dev->touch = (pkt[1] & 0x03) ? 1 : 0; + + return 1; +} +#endif + + /***************************************************************************** * the different device descriptors */ @@ -504,6 +526,17 @@ static struct usbtouch_device_info usbtouch_dev_info[] = { .read_data = dmc_tsc10_read_data, }, #endif + +#ifdef CONFIG_TOUCHSCREEN_USB_IRTOUCH + [DEVTYPE_IRTOUCH] = { + .min_xc = 0x0, + .max_xc = 0x0fff, + .min_yc = 0x0, + .max_yc = 0x0fff, + .rept_size = 8, + .read_data = irtouch_read_data, + }, +#endif };