Retrode Forum

General Category => Support => Topic started by: Damien on 08/Oct/2012 08:02:08 PM

Title: [Ubuntu 12.04] Controller 1 moves my mouse? (0.17h) [Solution: Use HIDMode 3]
Post by: Damien on 08/Oct/2012 08:02:08 PM
Hi, I recently patched to the latest firmware 0.17h only to find that with the default options the buttons pressed on the controller 1 port were not recognised anymore and that the directional pad moves my mouse cursor to the edges of my screen. I guessed it was because of the recent addition of snes mouse support so I have modified HIDMode from 1 to 2 as a workaround.

[edit] Is it related to the pinned down topic? My controller works, it just has an incorrect behaviour.
Title: Re: [Ubuntu 12.04] Controller 1 moves my mouse? (0.17h)
Post by: Matthias_H on 09/Oct/2012 02:36:28 PM
Hi, Are you using an original SNES controller or a 3rd-party product? I might have to revise the detection routine for the mouse, or move it into the config file altogether, since it is so rarely used.
Title: Re: [Ubuntu 12.04] Controller 1 moves my mouse? (0.17h)
Post by: shybry on 06/May/2013 05:13:17 AM
I have similar issues with the latest firmware (0.18c) for a Retrode 2 on Ubuntu 12.04. All original Nintendo/Sega controllers.

HIDMode 1:


$ ls -l /dev/input/by-id/|grep Retrode
lrwxrwxrwx 1 root root 10 May  5 23:16 usb-Retrode_UG_Retrode-if01-event-mouse -> ../event15
lrwxrwxrwx 1 root root  9 May  5 23:16 usb-Retrode_UG_Retrode-if01-mouse -> ../mouse2
lrwxrwxrwx 1 root root 10 May  5 23:16 usb-Retrode_UG_Retrode-if02-event-mouse -> ../event16
lrwxrwxrwx 1 root root  9 May  5 23:16 usb-Retrode_UG_Retrode-if02-mouse -> ../mouse3


HIDMode 2:


$ ls -l /dev/input/by-id/|grep Retrode
lrwxrwxrwx 1 root root 10 May  5 23:18 usb-Retrode_UG_Retrode-if01-event-joystick -> ../event15
lrwxrwxrwx 1 root root  6 May  5 23:18 usb-Retrode_UG_Retrode-if01-joystick -> ../js1


Is it possible that in HIDMode 1 that the joystick device(s?) might emit mouse events? The xboxdrv documentation (http://pingus.seul.org/~grumbel/xboxdrv/xboxdrv.html) implies that such behaviour would result in a mouse device being detected under Linux, though I might be reading between the lines too much:

QuoteTo make sure sure that a mouse, keyboard or joystick device is properly detected by Xorg, the kernel or libraries such [as] SDL xboxdrv will insert extra dummy events. For example a mouse device needs REL_X and REL_Y events to be detected as such, but a configuration that only wants to emulate the mouse buttons won't provide those, thus xboxdrv will add them automatically.

Using HIDMode 2 is a decent enough workaround for anything 1-or-2-player. Less than ideal for Bomberman or the like...
Title: Re: [Ubuntu 12.04] Controller 1 moves my mouse? (0.17h)
Post by: Matthias_H on 06/May/2013 03:46:49 PM
How about keyboard mode [HIDMode] 3? That should work even under the most adverse circumstances, and starting with FW version 0.18b or so it even supports a full four players.
Title: Re: [Ubuntu 12.04] Controller 1 moves my mouse? (0.17h)
Post by: shybry on 07/May/2013 02:12:50 AM
Oh, duh, I should have tried that. Yes, HIDMode 3 works fine. Thanks!