diff mbox

ET1602 Touchscreen doesn't work

Message ID BANLkTin3MyXsDHOK+BgdXvKO5YBH=Cv5DA@mail.gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

Chih-Wei Huang June 9, 2011, 11:26 a.m. UTC
2011/6/8 Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>:
> I was referring to Benjamin's multi-touch solution, perhaps, reverting
> the multi-device patch already. By the way, did you test it without the
> multi-device patch and did it work, or did you test it only with 2.6.32?

I'm not sure if I understood you correctly.
I did these:
* remove the quirk for touchpack in hid-quirks.c
* change hid-multitouch.c as suggested by Benjamin.

Test results:
* The touchscreen is detected by hid-core.
  (only one device is detected)
* Manually modprobe hid-multitouch,
  it didn't detect the touch device.
* The android framework correctly recognized
  the touchscreen and it works well.

The whole patch shows as below:

-       { USB_VENDOR_ID_TOUCHPACK, USB_DEVICE_ID_TOUCHPACK_RTS,
HID_QUIRK_MULTI_INPUT },
+//     { USB_VENDOR_ID_TOUCHPACK, USB_DEVICE_ID_TOUCHPACK_RTS,
HID_QUIRK_MULTI_INPUT },

        { USB_VENDOR_ID_ATEN, USB_DEVICE_ID_ATEN_UC100KM, HID_QUIRK_NOGET },
        { USB_VENDOR_ID_ATEN, USB_DEVICE_ID_ATEN_CS124U, HID_QUIRK_NOGET },

Comments

Thadeu Lima de Souza Cascardo June 9, 2011, 1:39 p.m. UTC | #1
On Thu, Jun 09, 2011 at 07:26:58PM +0800, Chih-Wei Huang wrote:
> 2011/6/8 Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>:
> > I was referring to Benjamin's multi-touch solution, perhaps, reverting
> > the multi-device patch already. By the way, did you test it without the
> > multi-device patch and did it work, or did you test it only with 2.6.32?
> 
> I'm not sure if I understood you correctly.
> I did these:
> * remove the quirk for touchpack in hid-quirks.c
> * change hid-multitouch.c as suggested by Benjamin.
> 
> Test results:
> * The touchscreen is detected by hid-core.
>   (only one device is detected)
> * Manually modprobe hid-multitouch,
>   it didn't detect the touch device.
> * The android framework correctly recognized
>   the touchscreen and it works well.
> 

Nice. That was one of the tests. But have you tested without the quirck
in hid-quirks and without the suggested change by Benjamin? Considering
the device would indicate it supports RX and Z axis, but not X and Y
axis, it should not work either in Android.

Regards,
Cascardo.

> The whole patch shows as below:
> 
> diff --git a/drivers/hid/hid-multitouch.c b/drivers/hid/hid-multitouch.c
> index 0c5e9c3..fab373a 100644
> --- a/drivers/hid/hid-multitouch.c
> +++ b/drivers/hid/hid-multitouch.c
> @@ -713,6 +713,11 @@ static const struct hid_device_id mt_devices[] = {
>                 HID_USB_DEVICE(USB_VENDOR_ID_TOUCH_INTL,
>                         USB_DEVICE_ID_TOUCH_INTL_MULTI_TOUCH) },
> 
> +       /* TouchPack touchscreen */
> +       { .driver_data = MT_CLS_DEFAULT,
> +               HID_USB_DEVICE(USB_VENDOR_ID_TOUCHPACK,
> +                       USB_DEVICE_ID_TOUCHPACK_RTS) },
> +
>         /* Unitec panels */
>         { .driver_data = MT_CLS_DEFAULT,
>                 HID_USB_DEVICE(USB_VENDOR_ID_UNITEC,
> diff --git a/drivers/hid/usbhid/hid-quirks.c b/drivers/hid/usbhid/hid-quirks.c
> index 9a94b64..727f363 100644
> --- a/drivers/hid/usbhid/hid-quirks.c
> +++ b/drivers/hid/usbhid/hid-quirks.c
> @@ -49,7 +49,7 @@ static const struct hid_blacklist {
>         { USB_VENDOR_ID_ETURBOTOUCH, USB_DEVICE_ID_ETURBOTOUCH,
> HID_QUIRK_MULTI_INPUT },
>         { USB_VENDOR_ID_PANTHERLORD,
> USB_DEVICE_ID_PANTHERLORD_TWIN_USB_JOYSTICK, HID_QUIRK_MULTI_INPUT |
> HID_QUIRK_SKIP_OUTPUT_REPORTS },
>         { USB_VENDOR_ID_PLAYDOTCOM,
> USB_DEVICE_ID_PLAYDOTCOM_EMS_USBII, HID_QUIRK_MULTI_INPUT },
> -       { USB_VENDOR_ID_TOUCHPACK, USB_DEVICE_ID_TOUCHPACK_RTS,
> HID_QUIRK_MULTI_INPUT },
> +//     { USB_VENDOR_ID_TOUCHPACK, USB_DEVICE_ID_TOUCHPACK_RTS,
> HID_QUIRK_MULTI_INPUT },
> 
>         { USB_VENDOR_ID_ATEN, USB_DEVICE_ID_ATEN_UC100KM, HID_QUIRK_NOGET },
>         { USB_VENDOR_ID_ATEN, USB_DEVICE_ID_ATEN_CS124U, HID_QUIRK_NOGET },
> 
> 
> -- 
> Chih-Wei
> Android-x86 project
> http://www.android-x86.org
Chih-Wei Huang June 10, 2011, 2:23 a.m. UTC | #2
2011/6/9 Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>:
> Nice. That was one of the tests. But have you tested without the quirck
> in hid-quirks and without the suggested change by Benjamin? Considering
> the device would indicate it supports RX and Z axis, but not X and Y
> axis, it should not work either in Android.

Did you mean just remove this line in hid-quirks.c?

{ USB_VENDOR_ID_TOUCHPACK, USB_DEVICE_ID_TOUCHPACK_RTS, HID_QUIRK_MULTI_INPUT },

That's what I've tried (with and without Benjamin's change) .
Yes, it works in Android 2.2.
Thadeu Lima de Souza Cascardo June 13, 2011, 3:09 p.m. UTC | #3
On Fri, Jun 10, 2011 at 10:23:06AM +0800, Chih-Wei Huang wrote:
> 2011/6/9 Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>:
> > Nice. That was one of the tests. But have you tested without the quirck
> > in hid-quirks and without the suggested change by Benjamin? Considering
> > the device would indicate it supports RX and Z axis, but not X and Y
> > axis, it should not work either in Android.
> 
> Did you mean just remove this line in hid-quirks.c?
> 
> { USB_VENDOR_ID_TOUCHPACK, USB_DEVICE_ID_TOUCHPACK_RTS, HID_QUIRK_MULTI_INPUT },
> 
> That's what I've tried (with and without Benjamin's change) .
> Yes, it works in Android 2.2.
> 

Yes, that's what I meant. The problem is: without the patch, X.org won't
work with the drivers I've tested it with; with the patch, Android won't
work. I am curious, because the code you've sent only checked for X and
Y axis and without the patch, the single device would not send events in
these axis, IIRC. I will check if I have this particular device
available and do some tests with current Linux (2.6.39.1) and more
recent X.org drivers.

Regards,
Cascardo.

> -- 
> Chih-Wei
> Android-x86 project
> http://www.android-x86.org
diff mbox

Patch

diff --git a/drivers/hid/hid-multitouch.c b/drivers/hid/hid-multitouch.c
index 0c5e9c3..fab373a 100644
--- a/drivers/hid/hid-multitouch.c
+++ b/drivers/hid/hid-multitouch.c
@@ -713,6 +713,11 @@  static const struct hid_device_id mt_devices[] = {
                HID_USB_DEVICE(USB_VENDOR_ID_TOUCH_INTL,
                        USB_DEVICE_ID_TOUCH_INTL_MULTI_TOUCH) },

+       /* TouchPack touchscreen */
+       { .driver_data = MT_CLS_DEFAULT,
+               HID_USB_DEVICE(USB_VENDOR_ID_TOUCHPACK,
+                       USB_DEVICE_ID_TOUCHPACK_RTS) },
+
        /* Unitec panels */
        { .driver_data = MT_CLS_DEFAULT,
                HID_USB_DEVICE(USB_VENDOR_ID_UNITEC,
diff --git a/drivers/hid/usbhid/hid-quirks.c b/drivers/hid/usbhid/hid-quirks.c
index 9a94b64..727f363 100644
--- a/drivers/hid/usbhid/hid-quirks.c
+++ b/drivers/hid/usbhid/hid-quirks.c
@@ -49,7 +49,7 @@  static const struct hid_blacklist {
        { USB_VENDOR_ID_ETURBOTOUCH, USB_DEVICE_ID_ETURBOTOUCH,
HID_QUIRK_MULTI_INPUT },
        { USB_VENDOR_ID_PANTHERLORD,
USB_DEVICE_ID_PANTHERLORD_TWIN_USB_JOYSTICK, HID_QUIRK_MULTI_INPUT |
HID_QUIRK_SKIP_OUTPUT_REPORTS },
        { USB_VENDOR_ID_PLAYDOTCOM,
USB_DEVICE_ID_PLAYDOTCOM_EMS_USBII, HID_QUIRK_MULTI_INPUT },