[PATCH] HID: hid-lg: Add USBID for Logitech G29 Wheel

Subsystems: hid core layer, the rest

STALE3997d

4 messages, 2 authors, 2015-09-28 · open the first message on its own page

[PATCH] HID: hid-lg: Add USBID for Logitech G29 Wheel

From: Simon Wood <hidden>
Date: 2015-07-24 01:10:21

Since this wheel is now available, and the USBID is listed on their website,
this patch adds it to allow the hid-lg4ff force feedback driver to find it.

I do not have this wheel to test with, but this should at least get it working
in emulation mode.

Note: There is probably more work required for adjust HID descriptor and handle
switching between emulation and native modes.

Signed-off-by: Simon Wood <redacted>
---
 drivers/hid/hid-ids.h | 1 +
 drivers/hid/hid-lg.c  | 2 ++
 2 files changed, 3 insertions(+)
diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h
index b04b082..653bfd4 100644
--- a/drivers/hid/hid-ids.h
+++ b/drivers/hid/hid-ids.h
@@ -599,6 +599,7 @@
 #define USB_DEVICE_ID_LOGITECH_DUAL_ACTION	0xc216
 #define USB_DEVICE_ID_LOGITECH_RUMBLEPAD2	0xc218
 #define USB_DEVICE_ID_LOGITECH_RUMBLEPAD2_2	0xc219
+#define USB_DEVICE_ID_LOGITECH_G29_WHEEL	0xc24f
 #define USB_DEVICE_ID_LOGITECH_WINGMAN_F3D	0xc283
 #define USB_DEVICE_ID_LOGITECH_FORCE3D_PRO	0xc286
 #define USB_DEVICE_ID_LOGITECH_FLIGHT_SYSTEM_G940	0xc287
diff --git a/drivers/hid/hid-lg.c b/drivers/hid/hid-lg.c
index 429340d..5332fb7 100644
--- a/drivers/hid/hid-lg.c
+++ b/drivers/hid/hid-lg.c
@@ -776,6 +776,8 @@ static const struct hid_device_id lg_devices[] = {
 		.driver_data = LG_FF },
 	{ HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_RUMBLEPAD2_2),
 		.driver_data = LG_FF },
+	{ HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_G29_WHEEL),
+		.driver_data = LG_FF4 },
 	{ HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_WINGMAN_F3D),
 		.driver_data = LG_FF },
 	{ HID_USB_DEVICE(USB_VENDOR_ID_LOGITECH, USB_DEVICE_ID_LOGITECH_FORCE3D_PRO),
-- 
2.1.4

Re: [PATCH] HID: hid-lg: Add USBID for Logitech G29 Wheel

From: Jiri Kosina <hidden>
Date: 2015-07-29 12:11:58

On Thu, 23 Jul 2015, Simon Wood wrote:
Since this wheel is now available, and the USBID is listed on their website,
this patch adds it to allow the hid-lg4ff force feedback driver to find it.

I do not have this wheel to test with, but this should at least get it working
in emulation mode.

Note: There is probably more work required for adjust HID descriptor and handle
switching between emulation and native modes.

Signed-off-by: Simon Wood <redacted>
I have applied this to for-4.3/logitech (and kept the "Note:" above in the 
changelog).

-- 
Jiri Kosina
SUSE Labs

Re: [PATCH] HID: hid-lg: Add USBID for Logitech G29 Wheel

From: <hidden>
Date: 2015-09-03 02:53:44

I do not have this wheel to test with, but this should at least get it
working in emulation mode.

Note: There is probably more work required for adjust HID descriptor and
handle switching between emulation and native modes.
I was able to get some more information, but as yet have not been able to
get time on the real hardware. Attached is a 2nd patch which should
improve the support, I'll formally submit it next week.... But if anyone
can test it first that would be great.

There's a pre-built Debian/Ubuntu kernel here:
https://dl.dropboxusercontent.com/u/34518077/linux-headers-4.2.0-g29%2B_20150831_i386.deb
https://dl.dropboxusercontent.com/u/34518077/linux-image-4.2.0-g29%2B_20150831_i386.deb

The wheel will need to be in PS3 mode set with switch behind LEDs, and
should connect first as a DF-EX (220' turn) and then automatically
reconnect as G29 (900' turn).

The mode should be selectable something like
--
root@retrobox:/home/simon# cd /sys/bus/hid/devices/0003\:046D\:C29B.0002
root@retrobox:/sys/bus/hid/devices/0003:046D:C29B.0002# ls
alternate_modes  country  driver  hidraw  input  leds  modalias  power 
range  real_id  report_descriptor  subsystem  uevent
root@retrobox:/sys/bus/hid/devices/0003:046D:C29B.0002# cat alternate_modes
native: G27 Racing Wheel *
DF-EX: Driving Force / Formula EX
DFP: Driving Force Pro
G25: G25 Racing Wheel
G27: G27 Racing Wheel *
root@retrobox:/sys/bus/hid/devices/0003:046D:C29B.0002# echo G25 >
alternate_modes
--

The LEDs should also work
--
root@retrobox:/home/simon/linux-git# cd /sys/class/leds/
root@retrobox:/sys/class/leds# ls
0003:046D:C29B.0005::RPM1  0003:046D:C29B.0005::RPM4  input3::numlock    
tpacpi::power       tpacpi::thinkvantage
0003:046D:C29B.0005::RPM2  0003:046D:C29B.0005::RPM5  input3::scrolllock 
tpacpi::standby
0003:046D:C29B.0005::RPM3  input3::capslock           phy0-led           
tpacpi::thinklight
root@retrobox:/sys/class/leds# echo 1 >
0003\:046D\:C29B.0005\:\:RPM1/brightness
--

Cheers,
Simon

Re: [PATCH] HID: hid-lg: Add USBID for Logitech G29 Wheel

From: Simon Wood <hidden>
Date: 2015-09-28 20:03:11

I was able to get some more information, but as yet have not been able to
 get time on the real hardware. Attached is a 2nd patch which should
improve the support, I'll formally submit it next week.... But if anyone
can test it first that would be great.
Obviously the 'submit next week' never happened... but I now have one of
these wheels to work on. The bad news is that the information we got does
not appear to be complete.

At present the wheel is mis-recognised as a G27 and forced into an
emulation state, it is somewhat usable in that mode.

If we send the 'G29 mode' command the wheel comes back with a device with
2x HID interfaces and that appears to screw up the probe (full log
attached).
--
Sep 28 12:30:33 retrobox kernel: [11079.944056] usb 2-1: new full-speed
USB device number 3 using uhci_hcd
Sep 28 12:30:33 retrobox kernel: [11080.113102] usb 2-1: New USB device
found, idVendor=046d, idProduct=c24f
Sep 28 12:30:33 retrobox kernel: [11080.113113] usb 2-1: New USB device
strings: Mfr=1, Product=2, SerialNumber=0
Sep 28 12:30:33 retrobox kernel: [11080.113120] usb 2-1: Product: G29
Driving Force Racing Wheel
Sep 28 12:30:33 retrobox kernel: [11080.113125] usb 2-1: Manufacturer:
Logitech
Sep 28 12:30:33 retrobox kernel: [11080.124431] input: Logitech G29
Driving Force Racing Wheel as
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1:1.0/0003:046D:C24F.0002/input/input10
Sep 28 12:30:33 retrobox kernel: [11080.125134] logitech
0003:046D:C24F.0002: input,hidraw0: USB HID v1.11 Joystick [Logitech G29
Driving Force Racing Wheel] on usb-0000:00:1d.0-1/input0
Sep 28 12:30:33 retrobox kernel: [11080.126094] logitech
0003:046D:C24F.0002: Force feedback support for Logitech Gaming Wheels
Sep 28 12:30:33 retrobox kernel: [11080.134307] logitech
0003:046D:C24F.0003: hiddev0,hidraw1: USB HID v1.11 Device [Logitech G29
Driving Force Racing Wheel] on usb-0000:00:1d.0-1/input1
Sep 28 12:30:33 retrobox kernel: [11080.134319] logitech
0003:046D:C24F.0003: not enough values in HID_OUTPUT_REPORT 0 field 0
Sep 28 12:30:33 retrobox kernel: [11080.134339] logitech: probe of
0003:046D:C24F.0003 failed with error -1
--

Any suggestions as to how we can 'ignore' or unbind the 2nd interface in
order to only work with the 1st?
Simon
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help