User Tools

Site Tools


doc:appunti:hardware:gamepad_dragonrise_eg_starts

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
doc:appunti:hardware:gamepad_dragonrise_eg_starts [2022/07/01 11:01] niccolodoc:appunti:hardware:gamepad_dragonrise_eg_starts [2022/07/01 12:40] – [Problems with GNU/Linux: disconnect loop] niccolo
Line 1: Line 1:
 ====== EG STARTS USB Joystick Interface ====== ====== EG STARTS USB Joystick Interface ======
  
-**EG STARTS** is a cheap (10 € in June 2022) circuit to connect a **joystick and buttons** to a PC via the **USB interface**. It is often used to build arcade-style consoles for retrogaming using the MAME software or alike, it is supported by the **GNU/Linux** operating system, but...+{{ eg-starts.jpg?260|EG STARTS Joystick interface}} 
 +The **EG STARTS** is a cheap (10 € in June 2022) circuit to connect a **joystick and buttons** to a PC via the **USB interface**. It is often used to build arcade-style consoles for retrogaming using the MAME software or alike, it is supported by the **GNU/Linux** operating system, but...
  
-===== Problems with recent Linux kernels =====+===== Problems with GNU/Linux: disconnect loop =====
  
-My first attempt to connect the EG STARTS to a **Raspberry Pi** running the operating system based on **Debian 11 Bullseye** was a total failure. The kernel started an **infinite loop** attaching and detaching the USB device:+My first attempt to connect the EG STARTS to a **Raspberry Pi** running the operating system based on **Debian 11 Bullseye** was a total failure. The kernel started an **infinite loop** detecting and disconnecting the USB device:
  
 <code> <code>
 +usb 2-1.2: new low speed USB device using ehci_hcd and address 7
 +usb 2-1.2: New USB device found, idVendor=0079, idProduct=0006
 +usb 2-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
 +usb 2-1.2: Product: Generic   USB  Joystick
 +usb 2-1.2: Manufacturer: DragonRise inc.
 +usb 2-1.2: configuration #1 chosen from 1 choice
 +input: DragonRise inc.   Generic   USB  Joystick   
 +    as /devices/pci0000:00/0000:00:1a.0/usb2/2-1/2-1.2/2-1.2:1.0/input/input81
 +dragonrise 0003:0079:0006.004E: input,hidraw2: USB HID v1.10 Joystick
 +    [DragonRise inc.   Generic   USB  Joystick  ] on usb-0000:00:1a.0-1.2/input0
 +dragonrise 0003:0079:0006.004E: Force Feedback for DragonRise Inc. game controllers
 +    by Richard Walmsley <richwalm@gmail.com>
 +usb 2-1.2: USB disconnect, address 7
 </code> </code>
  
 that loop was revealed also by the red **LED** on the interface **blinking** continously. that loop was revealed also by the red **LED** on the interface **blinking** continously.
  
 +The problem occurred too using different GNU/Linux distributions: Raspberry Pi OS, Debian GNU/Linux, GRML; all running various **kernel versions** from the **4.x** and **5.x** series. The problem is caused by the kernel driver **hid_dr**, used for **DragonRise Inc. game controller**.
 +
 +Running an old **2.6** version, the driver (named **hid_drff**) was stable enough to be able to read some input events from the device.
 +
 +Fortunately I found a workaround for this problem in these posts:
 +
 +  * **[[https://retropie.org.uk/forum/topic/31488/solved-repeated-disconnect-of-zero-delay-usb-encoder-dragonrise/|Repeated disconnect of Zero Delay USB encoder (DragonRise)]]**
 +  * **[[https://github.com/sriemer/fix-linux-mouse#usb-mouse-disconnectsreconnects-every-minute-on-linux|USB mouse disconnects/reconnects every minute on Linux]]**
 +
 +It seems that the problem is caused by the driver that continously does a **buffer overflows if it is not always polled** for events. In that cases the Linux kernel offers a workaround; just add the following option on the **kernel command line**:
 +
 +<file>
 +usbhid.quirks=0x0079:0x0006:0x00000400
 +</file>
 +In Debian and derived, just add that option into **/etc/default/grub**, at definition of **GRUB_CMDLINE_LINUX**, and execute **update-grub**. Notice that 0x79 is vendor code the and 0x06 is the product code, as revealed by **lsusb**:
 +
 +<code>
 +Bus 002 Device 009: ID 0079:0006 DragonRise Inc. Generic USB Joystick
 +</code>
doc/appunti/hardware/gamepad_dragonrise_eg_starts.txt · Last modified: 2022/07/01 12:41 by niccolo