Changes

Line 26: Line 26:  
===HID Joystick===
 
===HID Joystick===
   −
The HID description declares the number of axis and buttons, unfortunately it is corrupt.
+
The dongle has the USB ID 0x046D:0xC29C, the HID descriptor is (unfortunately) corrupt. Under Windows XP the device is seen as a HID device with a combined X/Y axis, Z axis and 11 buttons. Under Linux the device is seen as HID device with X, Y and Z axis, but no buttons.
   −
The solution (on Linux) is to re-write the descriptor on the fly, after that the 'joystick' is will function correctly.
+
<code>
 +
05 01 09 04 A1 01 A1 02 95 01 75 0A 15 00 26 FF
 +
03 35 00 46 FF 03 09 30 81 02 06 00 FF 95 02 75
 +
01 25 01 45 01 09 01 81 02 95 0B 19 01 29 0B 05
 +
09 81 02 06 00 FF 95 01 75 01 09 02 81 02 05 01
 +
75 08 26 FF 00 46 FF 00 09 31 09 32 95 02 81 02
 +
C0 A1 02 06 00 FF 95 07 09 03 91 02 C0 0A FF FF
 +
95 08 B1 02 C0
 +
</code>
 +
 
 +
The solution (on Linux) is to re-write the descriptor on the fly, after that the axis/buttons are recognized correctly (even though the wireless link is not active yet).
 +
<code>
 +
        if ((quirks & LG_WIIWHEEL) && rsize >= 101 &&
 +
                        rdesc[41] == 0x95 && rdesc[42] == 0x0B &&
 +
                        rdesc[47] == 0x05 && rdesc[48] == 0x09) {
 +
                dev_info(&hdev->dev, "fixing up Logitech WiiWheel button "
 +
                                "descriptor\n");
 +
                rdesc[41] = 0x05;
 +
                rdesc[42] = 0x09;
 +
                rdesc[47] = 0x95;
 +
                rdesc[48] = 0x0B;
 +
        }
 +
</code
    
===Force Feedback===
 
===Force Feedback===
49

edits