On 2/19/06, Michael Alladin <[EMAIL PROTECTED]> wrote: > see [kernel_src]/drivers/usb/input/hid-core.c this joypad belongs in the > big table of quirky devices, or perhaps it even warrants it's own driver > (like the xbox).
Great! Thanks for pointing out that file! (see my attached patch) On 2/19/06, Alan Stern <[EMAIL PROTECTED]> wrote: > you got probably wouldn't help very much. Clearly the device does start > off in a working state; otherwise it wouldn't even show up in > /proc/bus/usb/devices. That was very useful information to know. So obviously it started off by working, then somewhere along the init process it got confused and locked itself up until a re-probing reset it. I dug into the file Michael pointed out and have created a patch for this thing. The HID_QUIRK_NOGET flag was required to make it work (so I'm guessing whatever this "get" thing is that the flag is avoiding is what's been locking it ... couldn't find any documentation about any of the flags to know what was going on). With it set, this works right out of the box; none of these ugly usbmodules workarounds needed! The HID_QUIRK_MULTI_INPUT flag is required for it to register two js# nodes so we don't need the ugly hack in libsdl. Michael, Tim, and anyone else on this list wish a Dual Joypad, please test this patch and tell us if it works on yours' as well (possibly different revisions, though I expect we all have the same problem). I would like to see this in the kernel :) There is a 4-port version of this adapter, which has a similar hack in libsdl for the multi-input. I expect that one could also use the MULTI_INPUT quirk flag, and possibly the NOGET, as well. But I don't have one to test nor do I even know the device ID. Cheers, -AF
--- linux-2.6.14-ck8/drivers/usb/input/hid-core.c 2006-01-06 20:40:19.000000000 -0500 +++ linux-2.6.14-ck5/drivers/usb/input/hid-core.c 2006-02-19 15:07:03.000000000 -0500 @@ -1404,6 +1404,7 @@ #define USB_VENDOR_ID_WISEGROUP 0x0925 #define USB_DEVICE_ID_1_PHIDGETSERVO_20 0x8101 #define USB_DEVICE_ID_4_PHIDGETSERVO_20 0x8104 +#define USB_DEVICE_ID_DUAL_JOYPAD 0x8866 #define USB_VENDOR_ID_CODEMERCS 0x07c0 #define USB_DEVICE_ID_CODEMERCS_IOW40 0x1500 @@ -1550,6 +1551,7 @@ { USB_VENDOR_ID_BTC, USB_DEVICE_ID_BTC_KEYBOARD, HID_QUIRK_NOGET}, { USB_VENDOR_ID_CHICONY, USB_DEVICE_ID_CHICONY_USBHUB_KB, HID_QUIRK_NOGET}, { USB_VENDOR_ID_TANGTOP, USB_DEVICE_ID_TANGTOP_USBPS2, HID_QUIRK_NOGET }, + { USB_VENDOR_ID_WISEGROUP, USB_DEVICE_ID_DUAL_JOYPAD, HID_QUIRK_NOGET | HID_QUIRK_MULTI_INPUT }, { USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_POWERMOUSE, HID_QUIRK_2WHEEL_POWERMOUSE }, { USB_VENDOR_ID_A4TECH, USB_DEVICE_ID_A4TECH_WCP32PU, HID_QUIRK_2WHEEL_MOUSE_HACK_7 },