Homepage › Forums › RetroPie Project › Everything else related to the RetroPie Project › Configure controller pro u unofficial
- This topic has 16 replies, 3 voices, and was last updated 10 years ago by sebastien.
-
AuthorPosts
-
10/18/2014 at 15:17 #81870sebastienParticipant
Hello,
I bought a wii controller controlling pro unofficial.
I use retropie 2.3.
And I block at the launch of emulationstation, “No gamepads detected” …
The keys are well marked on evtest and i get to set well retroarch with retroarch-joyconfig.
Thank you for your help
10/22/2014 at 18:50 #81946sebastienParticipantThe result of evtest:
pi@RPI-CONSOLE ~ $ sudo evtest
No device specified, trying to scan all of /dev/input/event*
Available devices:
/dev/input/event0: HID 04f3:0103
/dev/input/event1: HID 04f3:0103
/dev/input/event2: Nintendo Wii Remote Accelerometer
/dev/input/event3: Nintendo Wii Remote IR
/dev/input/event4: Nintendo Wii Remote
/dev/input/event5: Nintendo Wii Remote Classic Controller
/dev/input/event6: Nintendo Wii Remote Motion Plus
Select the device event number [0-6]:/dev/input/event5 should be linked to /dev/input/js0 ?
pi@RPI-CONSOLE ~ $ ls /dev/input/
by-id event0 event2 event4 event6 js1
by-path event1 event3 event5 js0 miceThanks
10/26/2014 at 19:15 #82043sebastienParticipantpi@RPI-CONSOLE ~ $ sudo jstest /dev/input/js0
Driver version is 2.1.0.
Joystick (Nintendo Wii Remote) has 0 axes ()
and 7 buttons (BtnX, BtnY, ?, (null), (null), Btn1, Btn2).
Testing … (interrupt to exit)
Buttons: 0:off 1:off 2:off 3:off 4:off 5:off 6:offpi@RPI-CONSOLE ~ $ sudo jstest /dev/input/js1
Driver version is 2.1.0.
Joystick (Nintendo Wii Remote Classic Controller) has 6 axes (Hat1X, Hat1Y, Hat2X, Hat2Y, Hat3X, Hat3Y)
and 11 buttons (BtnX, BtnY, BtnTL, BtnTR, BtnTR2, BtnSelect, BtnStart, BtnMode, ?, (null), (null)).
Testing … (interrupt to exit)
Axes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:ofAxes: 0: 0 1: 0 2: 0 3: 0 4: 0 5: 0 Buttons: 0:off 1:off 2:off 3:off 4:off 5:off 6:off 7:off 8:off 9:off 10:offMy /etc/udev/rules.d/99-input.rules :
SUBSYSTEM==”input”, ATTRS{name}==”Nintendo Wii Remote Classic Controller”, MODE=”0666″, ENV{ID_INPUT_JOYSTICK}=”1″
How to “Nintendo Wii Remote Controller Classic” on js0?
Thanks
10/26/2014 at 20:02 #82049FloobMemberDoes it configure in RetroArch ok?
If so, you could manually write the keymappings into the es_input.cfg file?10/27/2014 at 18:19 #82091AnonymousInactive[quote=82043]
My /etc/udev/rules.d/99-input.rules :
SUBSYSTEM==”input”, ATTRS{name}==”Nintendo Wii Remote Classic Controller”, MODE=”0666″, ENV{ID_INPUT_JOYSTICK}=”1″
How to “Nintendo Wii Remote Controller Classic” on js0?
Thanks
[/quote]
Last time I got my hand on this, the file was in /etc/udev.rules.d/ (like /etc/udev.rules.d/98-wiiclassic.conf), not /etc/udev/rules.d/, are you sure about this path ?
You can check if the property is correctly applied withsudo udevadm info --query=all --name=input/eventXX
(https://hg.libsdl.org/SDL/file/704a0bfecf75/README-linux.txt#l57)
I think the property is not present, it looks like the problem I had, because everything else is working. You can also try with this simple program : https://hg.libsdl.org/SDL/file/b9663c77f5c9/src/joystick/linux/SDL_sysjoystick.c.I don’t know if the used version of SDL2 has changed, but as said in my comment (https://github.com/retropie/RetroPie-Setup/issues/256#issuecomment-52950792), the version 2.0.1 doesn’t rely on this property (even though it says so). In this case you need a “corrected” hid_wiimote.so that reports the right axes so SDL2 detects it.
10/27/2014 at 21:20 #82096sebastienParticipantThank you for your reply.
/etc/udev.rules.d/ The folder does not exist in my version.
I have 2 file /etc/udev/rules.d/:
40-scratch.rules and 99-input.rulesI tried to edit these files in all directions but nothing…
Here is the beginning of udevadm:
pi@RPI-CONSOLE ~ $ sudo udevadm info -a –name=input/event5
Udevadm info starts with the device specified by the devpath and then
walks up the chain of parent devices. It prints for every device
found, all possible attributes in the udev rules key format.
A rule to match, can be composed by the attributes of the device
and the attributes from one single parent device.looking at device ‘/devices/platform/bcm2708_usb/usb1/1-1/1-1.5/1-1.5:1.0/bluetooth/hci0/hci0:42/0005:057E:0306.000D/input/input55/event5’:
KERNEL==”event5″
SUBSYSTEM==”input”
DRIVER==””looking at parent device ‘/devices/platform/bcm2708_usb/usb1/1-1/1-1.5/1-1.5:1.0/bluetooth/hci0/hci0:42/0005:057E:0306.000D/input/input55’:
KERNELS==”input55″
SUBSYSTEMS==”input”
DRIVERS==””
ATTRS{name}==”Nintendo Wii Remote Classic Controller”
ATTRS{phys}==””
ATTRS{uniq}==””
ATTRS{properties}==”0″looking at parent device ‘/devices/platform/bcm2708_usb/usb1/1-1/1-1.5/1-1.5:1.0/bluetooth/hci0/hci0:42/0005:057E:0306.000D’:
KERNELS==”0005:057E:0306.000D”
SUBSYSTEMS==”hid”
DRIVERS==”wiimote”
ATTRS{devtype}==”gen10″
ATTRS{extension}==”classic”……………………………………….
js0 :pi@RPI-CONSOLE ~ $ sudo udevadm info -a –name=input/js0
Udevadm info starts with the device specified by the devpath and then
walks up the chain of parent devices. It prints for every device
found, all possible attributes in the udev rules key format.
A rule to match, can be composed by the attributes of the device
and the attributes from one single parent device.looking at device ‘/devices/platform/bcm2708_usb/usb1/1-1/1-1.5/1-1.5:1.0/bluetooth/hci0/hci0:42/0005:057E:0306.000D/input/input52/js0’:
KERNEL==”js0″
SUBSYSTEM==”input”
DRIVER==””looking at parent device ‘/devices/platform/bcm2708_usb/usb1/1-1/1-1.5/1-1.5:1.0/bluetooth/hci0/hci0:42/0005:057E:0306.000D/input/input52’:
KERNELS==”input52″
SUBSYSTEMS==”input”
DRIVERS==””
ATTRS{name}==”Nintendo Wii Remote”
ATTRS{phys}==””
ATTRS{uniq}==””
ATTRS{properties}==”0″looking at parent device ‘/devices/platform/bcm2708_usb/usb1/1-1/1-1.5/1-1.5:1.0/bluetooth/hci0/hci0:42/0005:057E:0306.000D’:
KERNELS==”0005:057E:0306.000D”
SUBSYSTEMS==”hid”
DRIVERS==”wiimote”
ATTRS{devtype}==”gen10″
ATTRS{extension}==”classic”………………………………………………
js1 :pi@RPI-CONSOLE ~ $ sudo udevadm info -a –name=input/js1
Udevadm info starts with the device specified by the devpath and then
walks up the chain of parent devices. It prints for every device
found, all possible attributes in the udev rules key format.
A rule to match, can be composed by the attributes of the device
and the attributes from one single parent device.looking at device ‘/devices/platform/bcm2708_usb/usb1/1-1/1-1.5/1-1.5:1.0/bluetooth/hci0/hci0:42/0005:057E:0306.000D/input/input55/js1’:
KERNEL==”js1″
SUBSYSTEM==”input”
DRIVER==””looking at parent device ‘/devices/platform/bcm2708_usb/usb1/1-1/1-1.5/1-1.5:1.0/bluetooth/hci0/hci0:42/0005:057E:0306.000D/input/input55’:
KERNELS==”input55″
SUBSYSTEMS==”input”
DRIVERS==””
ATTRS{name}==”Nintendo Wii Remote Classic Controller”
ATTRS{phys}==””
ATTRS{uniq}==””
ATTRS{properties}==”0″looking at parent device ‘/devices/platform/bcm2708_usb/usb1/1-1/1-1.5/1-1.5:1.0/bluetooth/hci0/hci0:42/0005:057E:0306.000D’:
KERNELS==”0005:057E:0306.000D”
SUBSYSTEMS==”hid”
DRIVERS==”wiimote”
ATTRS{devtype}==”gen10″
ATTRS{extension}==”classic”10/27/2014 at 23:03 #82100AnonymousInactiveHum, right, I misspelled the path, it is /etc/udev/rules.d/ (and I named the file 99-joystick.rules), but anyway your rule is not being applied (or the command you used to check is not showing this property, are you sure about the “-a” option vs “–query=all” ?) ; you should have an output like this :
pi@raspberrypi ~ $ sudo udevadm info --query=all --name=input/event6 P: /devices/platform/bcm2708_usb/usb1/1-1/1-1.2/1-1.2:1.0/bluetooth/hci0/hci0:71/0005:057E:0306.0005/input/input4/event6 N: input/event6 E: BACKSPACE=guess E: DEVNAME=/dev/input/event6 E: DEVPATH=/devices/platform/bcm2708_usb/usb1/1-1/1-1.2/1-1.2:1.0/bluetooth/hci0/hci0:71/0005:057E:0306.0005/input/input4/event6 E: ID_INPUT=1 E: ID_INPUT_JOYSTICK=1 E: ID_INPUT_KEY=1 E: MAJOR=13 E: MINOR=70 E: SUBSYSTEM=input E: UDEV_LOG=3 E: USEC_INITIALIZED=407332809 E: XKBLAYOUT=fr E: XKBMODEL=pc105
If you still don’t have it, maybe some rights problems on the file ? Have you reloaded udev/restarted the Pi after touching the udev rules ?
But like I said, if SDL2.0.1 is used, this will not even solve your problem, you’ll need a modified hid-wiimote module (I have a precompiled one assuming it’s still the same kernel version).10/29/2014 at 19:28 #82170sebastienParticipantI created a new file /etc/udev/rules.d/99-joystick.rules:
SUBSYSTEM == “input”, ATTRS {name} == “Nintendo Wii Remote Controller Classic”, MODE = “0666”, ENV {ID_INPUT_JOYSTICK} = “1”
But I have always the same thing. I have to restart the udev service and even the RPI.
The udevadm command gives me this:
pi@RPI-CONSOLE ~ $ sudo udevadm info –query=all –name=input/event5
P: /devices/platform/bcm2708_usb/usb1/1-1/1-1.5/1-1.5:1.0/bluetooth/hci0/hci0:43/0005:057E:0306.0003/input/input5/event5
N: input/event5
E: BACKSPACE=guess
E: DEVNAME=/dev/input/event5
E: DEVPATH=/devices/platform/bcm2708_usb/usb1/1-1/1-1.5/1-1.5:1.0/bluetooth/hci0/hci0:43/0005:057E:0306.0003/input/input5/event5
E: ID_INPUT=1
E: ID_INPUT_JOYSTICK=1
E: ID_INPUT_KEY=1
E: MAJOR=13
E: MINOR=69
E: SUBSYSTEM=input
E: UDEV_LOG=3
E: USEC_INITIALIZED=16369308809
E: XKBLAYOUT=fr
E: XKBMODEL=pc105pi@RPI-CONSOLE ~ $ sudo udevadm info –query=all –name=input/js0
P: /devices/platform/bcm2708_usb/usb1/1-1/1-1.5/1-1.5:1.0/bluetooth/hci0/hci0:43/0005:057E:0306.0003/input/input2/js0
N: input/js0
E: DEVNAME=/dev/input/js0
E: DEVPATH=/devices/platform/bcm2708_usb/usb1/1-1/1-1.5/1-1.5:1.0/bluetooth/hci0/hci0:43/0005:057E:0306.0003/input/input2/js0
E: ID_INPUT=1
E: ID_INPUT_KEY=1
E: MAJOR=13
E: MINOR=0
E: SUBSYSTEM=input
E: UDEV_LOG=3
E: USEC_INITIALIZED=16368977015I also installed your modified version:
https://github.com/Alex131089/raspberrypi-linux-3.6Thank you
10/30/2014 at 16:01 #82221AnonymousInactiveThe rule is applied, so I guess it’s still SDL 2.0.1 being used.
The modified version you linked was for the old kernel actually (I hope you didn’t lost your time compiling this ^^).
You can use this module http://alex131089.info/rpi/ if it’s still the same kernel version, or use this modified source to compile the module against your kernel version : https://gist.github.com/Alex131089/01177d7bc593948cac9f/c1839f6f7fab66e78814afeefa4f65259d06e8a4#file-hid-wiimote-modules-c-L1003
Another solution would be to compile EmulationStation against SDL 2.0.2 at least.Edit: btw,
How to “Nintendo Wii Remote Controller Classic” on js0?
It doesn’t necessarily have to be on js0 ;)
10/30/2014 at 21:01 #82227sebastienParticipantMy kernel is the 3.12.29+ release.
How do we compile your file hid-wiimote-modules.c?
With the gcc command?
I try this :
sudo gcc -o hid-wiimote-modules.o hid-wiimote-modules.c
hid-wiimote-modules.c:36:26: fatal error: linux/device.h: Aucun fichier ou dossier de ce type
compilation terminated.Thank you
11/01/2014 at 15:32 #82300AnonymousInactiveI don’t have the exact operating guide, here some links/documentation I used to manage to compile the module :
http://stackoverflow.com/questions/12151694/how-to-find-the-version-of-a-linux-kernel-source-tree
http://www.raspberrypi.org/documentation/linux/kernel/building.md
http://93.93.128.176/forums/viewtopic.php?f=28&t=73005
http://raspberrypi.stackexchange.com/questions/10223/difference-between-3-6-11-and-3-6-11
http://unix.stackexchange.com/questions/125624/unable-to-load-module-disagrees-about-version-of-symbol-module-layout
http://raspberrypi.stackexchange.com/questions/10289/raspbian-kernel-module-segmentation-fault/10299#10299
http://bchavez.bitarmory.com/archive/2013/01/16/compiling-kernel-modules-for-raspberry-pi.aspx
http://forum.stmlabs.com/showthread.php?tid=7671
http://www.raspberrypi.org/forums/viewtopic.php?f=66&t=27413
http://www.raspberrypi.org/forums/viewtopic.php?f=66&t=25964#p236660
http://www.raspberrypi.org/forums/viewtopic.php?f=71&t=17666
http://raspberrypi.stackexchange.com/questions/1273/where-is-the-kernel-source-for-raspbians-default-3-1-9-kernel
http://www.raspberrypi.org/forums/viewtopic.php?f=66&t=57401
http://www.gurucoding.com/en/rpi_cross_compiler/diff_hardfp_softfp.phpNote that you don’t necessarily have to compile the whole kernel for a single module if you have the symbole file (and you have to or the module will not load into the kernel).
11/03/2014 at 21:12 #82398sebastienParticipantCool my controllers work!
So i rewrite a clean image on the SD card to install your precompiled module hid-wiimote for 3.12.22+ kernel.
One last question. This is about the LED on the controller. I own 2 controllers of this type and only the LED n°1 is supported.
I used your script to associate my controllers:
https://github.com/Alex131089/Super-RPi/tree/master/etc/profile.d
Thank you
11/03/2014 at 22:43 #82399AnonymousInactiveDo you also have https://github.com/Alex131089/Super-RPi/blob/master/home/pi/WiimoteConnect.sh (as you can see in the link you give) ?
Because this script is in charge of settings the leds ; actually it can works without setting the led number, but you have to know which player is each controller.
If this script don’t works, try to debug it by running it yourself in a terminal with enought privileges then ;)
The logic to get the led number is a bit tricky though (have to find the right number using informations from /sys).11/05/2014 at 21:14 #82449sebastienParticipantYes I am also WiimoteConnect script in /home/pi
The first controller connected become the first player.
Where we put in your script the second controller must be LED n°2?
In my case I have:
1st Controller: /dev/input/event3
2nd Controller: /dev/input/event8Thank you
11/06/2014 at 23:55 #82477AnonymousInactiveAs seen in the source code :
count = 0
# For each input (must be in numerical order of js*)
# If Nintendo remote, count it
count=$((count+1))
# If mine, set position & quit
set all leds to 0
set the led $count to enabledWhat else do you need ?
11/07/2014 at 17:59 #82496sebastienParticipantThis script works for you ?
LEDs light up well in order?
I just first to the LED lights on every controllers .
Thank you
11/12/2014 at 18:33 #82666sebastienParticipantNothing to do with the LED.
I noticed that the directional sticks does not work.
But they are well recognized with the retroarch joyconfig command.
retroarch.cfg :
input_player1_joypad_index = “0”
input_player1_b_btn = “1”
input_player1_y_btn = “3”
input_player1_select_btn = “10”
input_player1_start_btn = “9”
input_player1_up_btn = “h0up”
input_player1_down_btn = “h0down”
input_player1_left_btn = “h0left”
input_player1_right_btn = “h0right”
input_player1_a_btn = “0”
input_player1_x_btn = “2”
input_player1_l_btn = “4”
input_player1_r_btn = “5”
input_player1_l2_btn = “6”
input_player1_r2_btn = “7”
input_player1_l3_btn = “10”
input_player1_r3_btn = “10”
input_player1_l_x_plus_axis = “+0”
input_player1_l_x_minus_axis = “-0”
input_player1_l_y_plus_axis = “-1”
input_player1_l_y_minus_axis = “+1”
input_player1_r_x_plus_axis = “+2”
input_player1_r_x_minus_axis = “-2”
input_player1_r_y_plus_axis = “-3”
input_player1_r_y_minus_axis = “+3”Thank you
-
AuthorPosts
- The forum ‘Everything else related to the RetroPie Project’ is closed to new topics and replies.