|
Post by MASHtm on Jan 1, 2019 16:39:32 GMT
Hi!
I try to activate my xbox 360 wireless usb adapter from Microsoft.
Bus 001 Device 009: ID 045e:0719 Microsoft Corp. Xbox 360 Wireless Adapter Usually this works with the xpad kernel module which is not included in the firmware.
I'm wondering if someone would be so kind to build the module with it's dependencies for me? I'm already able to boot in FEL mode and to modify the contents of "/dev/nandb".
Greetings, MASHtm
|
|
|
Post by jj0 on Jan 7, 2019 16:12:05 GMT
Hi! I try to activate my xbox 360 wireless usb adapter from Microsoft. Bus 001 Device 009: ID 045e:0719 Microsoft Corp. Xbox 360 Wireless Adapter Usually this works with the xpad kernel module which is not included in the firmware. I'm wondering if someone would be so kind to build the module with it's dependencies for me? I'm already able to boot in FEL mode and to modify the contents of "/dev/nandb". Greetings, MASHtm Try the attached one. It loads without errors on my Mini, bua as for teh life of me I can't find my xbox 360 wireless USB adapter I haven't been able to test it. Attachments:xpad.ko (177.15 KB)
|
|
|
Post by MASHtm on Jan 8, 2019 0:01:54 GMT
Thanks a lot for providing the kernel module! I tried to "insmod -f" it after FEL boot and it loaded cleanly. I see
[ 170.903496] usbcore: registered new interface driver xpad [ 280.784039] usb 5-1: new full-speed USB device number 3 using sw-ohci [ 280.975048] usb 5-1: New USB device found, idVendor=045e, idProduct=0719 [ 280.982562] usb 5-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3 [ 280.990549] usb 5-1: Product: Xbox 360 Wireless Receiver for Windows [ 280.997663] usb 5-1: Manufacturer: ©Microsoft [ 281.002612] usb 5-1: SerialNumber: ..... If I turn on the Xpad I see
[ 281.994687] input: Xbox 360 Wireless Receiver as /devices/platform/sw-ohci.2/usb5/5-1/5-1:1.0/input/input4 But I still see all 4 green LEDs blinking. I guessed that it's maybe caused by lack of CONFIG_JOYSTICK_XPAD_LEDS support and continued...
I added a init script /etc/init.d/S50xpad and tried to boot normally. After some debugging I recognized that the builtin insmod does not support "-f" and fails without. So I copied your "kmod" to /root of the nand and softlinked it as "insmod". The final script looks like:
#!/bin/sh # # Start xpad #
case "$1" in start) printf "loading xpad.ko...: " # lsmod >/xpad.lsmod # /root/insmod -f /lib/modules/3.4.39/xpad.ko >/xpad.insmod 2>&1 /root/insmod -f /lib/modules/3.4.39/xpad.ko >/dev/null 2>&1 RC=$? # echo $RC >/xpad.rc # dmesg|tail -100 >/xpad.dmesg # lsmod >/xpad.lsmod [ $RC = 0 ] && echo "OK" || echo "FAIL" ;; stop) printf "unloading xpad.ko...: " rmmod xpad RC=$? [ $RC = 0 ] && echo "OK" || echo "FAIL" ;; restart|reload) "$0" stop "$0" start ;; *) echo "Usage: $0 {start|stop|restart}" exit 1 esac
exit $RC
And it works! LEDs are still blinking, but I can use the Pad. Now it's time to modify gamecontrollerdb.txt
Thanks a lot again for your efforts!
|
|
|
Post by jj0 on Jan 8, 2019 6:31:56 GMT
Thanks a lot for providing the kernel module! I tried to "insmod -f" it after FEL boot and it loaded cleanly. I see
[ 170.903496] usbcore: registered new interface driver xpad [ 280.784039] usb 5-1: new full-speed USB device number 3 using sw-ohci [ 280.975048] usb 5-1: New USB device found, idVendor=045e, idProduct=0719 [ 280.982562] usb 5-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3 [ 280.990549] usb 5-1: Product: Xbox 360 Wireless Receiver for Windows [ 280.997663] usb 5-1: Manufacturer: ©Microsoft [ 281.002612] usb 5-1: SerialNumber: ..... If I turn on the Xpad I see
[ 281.994687] input: Xbox 360 Wireless Receiver as /devices/platform/sw-ohci.2/usb5/5-1/5-1:1.0/input/input4
<SNIP>
But I still see all 4 green LEDs blinking. I guessed that it's maybe caused by lack of CONFIG_JOYSTICK_XPAD_LEDS support and continued...
<span style="font-family: Verdana, Arial; font-size: 10pt;">And it works! LEDs are still blinking, but I can use the Pad. Now it's time to modify gamecontrollerdb.txt </span><img src="//storage.proboards.com/forum/images/smiley/smiley.png" alt=" " class="smile" style="font-family: Verdana, Arial; font-size: 10pt;"> Thanks a lot again for your efforts!
Cool! Thanks for reporting back. Nice that it works. I'm surprised you need to force loading with '-f'. I compiled it with the Modules.symvers from the Mini and on mine (fw 1_2_0-shield) the busybox insmod loads it OK. Regarding the LEDs, the C64Mini kernel doesn't have LED driver support enabled. I tried an xpad.ko with CONFIG_JOYSTICK_XPAD_FF=y and CONFIG_JOYSTICK_XPAD_LEDS=y but no /sys/class/leds/xpad0/... appeared. Maybe I can provide LED support as a module too.
|
|
|
Post by MASHtm on Jan 8, 2019 9:45:56 GMT
Cool! Thanks for reporting back. Nice that it works. I'm surprised you need to force loading with '-f'. I compiled it with the Modules.symvers from the Mini and on mine (fw 1_2_0-shield) the busybox insmod loads it OK. Regarding the LEDs, the C64Mini kernel doesn't have LED driver support enabled. I tried an xpad.ko with CONFIG_JOYSTICK_XPAD_FF=y and CONFIG_JOYSTICK_XPAD_LEDS=y but no /sys/class/leds/xpad0/... appeared. Maybe I can provide LED support as a module too. Ok, I'll try again with original insmod without -f. I only tried it with your kernel and assumed the rest;-) Most likely "modprobe" works as well then. AFAIK XPAD_FF provides Force Feedback support, depends on CONFIG_INPUT_FF_MEMLESS and is not needed. XPAD_LEDS depends on CONFIG_LEDS_CLASS according to Kconfig.
|
|
|
Post by darbyram on Jan 8, 2019 17:42:00 GMT
I suppose this should work with most Xbox controller's, as well as other gamepads as some use the xpad.ko driver?
|
|
|
Post by jj0 on Jan 8, 2019 20:08:24 GMT
I suppose this should work with most Xbox controller's, as well as other gamepads as some use the xpad.ko driver? Yes, there are a lot of controllers defined in the sourcecode:
{ 0x0079, 0x18d4, "GPD Win 2 X-Box Controller", 0, XTYPE_XBOX360 }, { 0x044f, 0x0f00, "Thrustmaster Wheel", 0, XTYPE_XBOX }, { 0x044f, 0x0f03, "Thrustmaster Wheel", 0, XTYPE_XBOX }, { 0x044f, 0x0f07, "Thrustmaster, Inc. Controller", 0, XTYPE_XBOX }, { 0x044f, 0x0f10, "Thrustmaster Modena GT Wheel", 0, XTYPE_XBOX }, { 0x044f, 0xb326, "Thrustmaster Gamepad GP XID", 0, XTYPE_XBOX360 }, { 0x045e, 0x0202, "Microsoft X-Box pad v1 (US)", 0, XTYPE_XBOX }, { 0x045e, 0x0285, "Microsoft X-Box pad (Japan)", 0, XTYPE_XBOX }, { 0x045e, 0x0287, "Microsoft Xbox Controller S", 0, XTYPE_XBOX }, { 0x045e, 0x0288, "Microsoft Xbox Controller S v2", 0, XTYPE_XBOX }, { 0x045e, 0x0289, "Microsoft X-Box pad v2 (US)", 0, XTYPE_XBOX }, { 0x045e, 0x028e, "Microsoft X-Box 360 pad", 0, XTYPE_XBOX360 }, { 0x045e, 0x028f, "Microsoft X-Box 360 pad v2", 0, XTYPE_XBOX360 }, { 0x045e, 0x0291, "Xbox 360 Wireless Receiver (XBOX)", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX360W }, { 0x045e, 0x02d1, "Microsoft X-Box One pad", 0, XTYPE_XBOXONE }, { 0x045e, 0x02dd, "Microsoft X-Box One pad (Firmware 2015)", 0, XTYPE_XBOXONE }, { 0x045e, 0x02e3, "Microsoft X-Box One Elite pad", 0, XTYPE_XBOXONE }, { 0x045e, 0x02ea, "Microsoft X-Box One S pad", 0, XTYPE_XBOXONE }, { 0x2e24, 0x0652, "Hyperkin Duke X-Box One pad", 0, XTYPE_XBOXONE }, { 0x045e, 0x0719, "Xbox 360 Wireless Receiver", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX360W }, { 0x046d, 0xc21d, "Logitech Gamepad F310", 0, XTYPE_XBOX360 }, { 0x046d, 0xc21e, "Logitech Gamepad F510", 0, XTYPE_XBOX360 }, { 0x046d, 0xc21f, "Logitech Gamepad F710", 0, XTYPE_XBOX360 }, { 0x046d, 0xc242, "Logitech Chillstream Controller", 0, XTYPE_XBOX360 }, { 0x046d, 0xca84, "Logitech Xbox Cordless Controller", 0, XTYPE_XBOX }, { 0x046d, 0xca88, "Logitech Compact Controller for Xbox", 0, XTYPE_XBOX }, { 0x046d, 0xca8a, "Logitech Precision Vibration Feedback Wheel", 0, XTYPE_XBOX }, { 0x046d, 0xcaa3, "Logitech DriveFx Racing Wheel", 0, XTYPE_XBOX360 }, { 0x056e, 0x2004, "Elecom JC-U3613M", 0, XTYPE_XBOX360 }, { 0x05fd, 0x1007, "Mad Catz Controller (unverified)", 0, XTYPE_XBOX }, { 0x05fd, 0x107a, "InterAct 'PowerPad Pro' X-Box pad (Germany)", 0, XTYPE_XBOX }, { 0x05fe, 0x3030, "Chic Controller", 0, XTYPE_XBOX }, { 0x05fe, 0x3031, "Chic Controller", 0, XTYPE_XBOX }, { 0x062a, 0x0020, "Logic3 Xbox GamePad", 0, XTYPE_XBOX }, { 0x062a, 0x0033, "Competition Pro Steering Wheel", 0, XTYPE_XBOX }, { 0x06a3, 0x0200, "Saitek Racing Wheel", 0, XTYPE_XBOX }, { 0x06a3, 0x0201, "Saitek Adrenalin", 0, XTYPE_XBOX }, { 0x06a3, 0xf51a, "Saitek P3600", 0, XTYPE_XBOX360 }, { 0x0738, 0x4506, "Mad Catz 4506 Wireless Controller", 0, XTYPE_XBOX }, { 0x0738, 0x4516, "Mad Catz Control Pad", 0, XTYPE_XBOX }, { 0x0738, 0x4520, "Mad Catz Control Pad Pro", 0, XTYPE_XBOX }, { 0x0738, 0x4522, "Mad Catz LumiCON", 0, XTYPE_XBOX }, { 0x0738, 0x4526, "Mad Catz Control Pad Pro", 0, XTYPE_XBOX }, { 0x0738, 0x4530, "Mad Catz Universal MC2 Racing Wheel and Pedals", 0, XTYPE_XBOX }, { 0x0738, 0x4536, "Mad Catz MicroCON", 0, XTYPE_XBOX }, { 0x0738, 0x4540, "Mad Catz Beat Pad", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x0738, 0x4556, "Mad Catz Lynx Wireless Controller", 0, XTYPE_XBOX }, { 0x0738, 0x4586, "Mad Catz MicroCon Wireless Controller", 0, XTYPE_XBOX }, { 0x0738, 0x4588, "Mad Catz Blaster", 0, XTYPE_XBOX }, { 0x0738, 0x45ff, "Mad Catz Beat Pad (w/ Handle)", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x0738, 0x4716, "Mad Catz Wired Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x0738, 0x4718, "Mad Catz Street Fighter IV FightStick SE", 0, XTYPE_XBOX360 }, { 0x0738, 0x4726, "Mad Catz Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x0738, 0x4728, "Mad Catz Street Fighter IV FightPad", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0738, 0x4736, "Mad Catz MicroCon Gamepad", 0, XTYPE_XBOX360 }, { 0x0738, 0x4738, "Mad Catz Wired Xbox 360 Controller (SFIV)", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0738, 0x4740, "Mad Catz Beat Pad", 0, XTYPE_XBOX360 }, { 0x0738, 0x4743, "Mad Catz Beat Pad Pro", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x0738, 0x4758, "Mad Catz Arcade Game Stick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0738, 0x4a01, "Mad Catz FightStick TE 2", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOXONE }, { 0x0738, 0x6040, "Mad Catz Beat Pad Pro", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x0738, 0x9871, "Mad Catz Portable Drum", 0, XTYPE_XBOX360 }, { 0x0738, 0xb726, "Mad Catz Xbox controller - MW2", 0, XTYPE_XBOX360 }, { 0x0738, 0xb738, "Mad Catz MVC2TE Stick 2", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0738, 0xbeef, "Mad Catz JOYTECH NEO SE Advanced GamePad", XTYPE_XBOX360 }, { 0x0738, 0xcb02, "Saitek Cyborg Rumble Pad - PC/Xbox 360", 0, XTYPE_XBOX360 }, { 0x0738, 0xcb03, "Saitek P3200 Rumble Pad - PC/Xbox 360", 0, XTYPE_XBOX360 }, { 0x0738, 0xcb29, "Saitek Aviator Stick AV8R02", 0, XTYPE_XBOX360 }, { 0x0738, 0xf738, "Super SFIV FightStick TE S", 0, XTYPE_XBOX360 }, { 0x07ff, 0xffff, "Mad Catz GamePad", 0, XTYPE_XBOX360 }, { 0x0c12, 0x0005, "Intec wireless", 0, XTYPE_XBOX }, { 0x0c12, 0x8801, "Nyko Xbox Controller", 0, XTYPE_XBOX }, { 0x0c12, 0x8802, "Zeroplus Xbox Controller", 0, XTYPE_XBOX }, { 0x0c12, 0x8809, "RedOctane Xbox Dance Pad", DANCEPAD_MAP_CONFIG, XTYPE_XBOX }, { 0x0c12, 0x880a, "Pelican Eclipse PL-2023", 0, XTYPE_XBOX }, { 0x0c12, 0x8810, "Zeroplus Xbox Controller", 0, XTYPE_XBOX }, { 0x0c12, 0x9902, "HAMA VibraX - *FAULTY HARDWARE*", 0, XTYPE_XBOX }, { 0x0d2f, 0x0002, "Andamiro Pump It Up pad", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x0e4c, 0x1097, "Radica Gamester Controller", 0, XTYPE_XBOX }, { 0x0e4c, 0x1103, "Radica Gamester Reflex", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX }, { 0x0e4c, 0x2390, "Radica Games Jtech Controller", 0, XTYPE_XBOX }, { 0x0e4c, 0x3510, "Radica Gamester", 0, XTYPE_XBOX }, { 0x0e6f, 0x0003, "Logic3 Freebird wireless Controller", 0, XTYPE_XBOX }, { 0x0e6f, 0x0005, "Eclipse wireless Controller", 0, XTYPE_XBOX }, { 0x0e6f, 0x0006, "Edge wireless Controller", 0, XTYPE_XBOX }, { 0x0e6f, 0x0008, "After Glow Pro Controller", 0, XTYPE_XBOX }, { 0x0e6f, 0x0105, "HSM3 Xbox360 dancepad", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0e6f, 0x0113, "Afterglow AX.1 Gamepad for Xbox 360", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x011f, "Rock Candy Gamepad Wired Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0131, "PDP EA Sports Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0133, "Xbox 360 Wired Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0139, "Afterglow Prismatic Xbox One Wired Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02b3, "Afterglow Prismatic Xbox One Wired Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02b8, "Afterglow Prismatic Wired Controller for Xbox One", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x013a, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0146, "Rock Candy Wired Controller for Xbox One", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0147, "PDP Marvel Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x015c, "PDP Xbox One Arcade Stick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOXONE }, { 0x0e6f, 0x0161, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0162, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0163, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a0, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a1, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a7, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a8, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0164, "PDP Battlefield One", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0165, "PDP Titanfall 2", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0201, "Pelican PL-3601 'TSZ' Wired Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0213, "Afterglow Gamepad for Xbox 360", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x021f, "Rock Candy Gamepad for Xbox 360", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0246, "Rock Candy Gamepad for Xbox One 2015", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02ab, "PDP Controller for Xbox One", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a2, "PDP Wired Controller for Xbox One - Crimson Red", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a4, "PDP Wired Controller for Xbox One - Stealth Series", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a6, "PDP Wired Controller for Xbox One - Camo Series", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02ad, "PDP Wired Controller for Xbox One - Stealth Series", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0301, "Logic3 Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0346, "Rock Candy Gamepad for Xbox One 2016", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0401, "Logic3 Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0413, "Afterglow AX.1 Gamepad for Xbox 360", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0501, "PDP Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0xf900, "PDP Afterglow AX.1", 0, XTYPE_XBOX360 }, { 0x0e8f, 0x0201, "SmartJoy Frag Xpad/PS2 adaptor", 0, XTYPE_XBOX }, { 0x0e8f, 0x3008, "Generic xbox control (dealextreme)", 0, XTYPE_XBOX }, { 0x0f0d, 0x000a, "Hori Co. DOA4 FightStick", 0, XTYPE_XBOX360 }, { 0x0f0d, 0x000c, "Hori PadEX Turbo", 0, XTYPE_XBOX360 }, { 0x0f0d, 0x000d, "Hori Fighting Stick EX2", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0f0d, 0x0016, "Hori Real Arcade Pro.EX", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0f0d, 0x001b, "Hori Real Arcade Pro VX", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0f0d, 0x0063, "Hori Real Arcade Pro Hayabusa (USA) Xbox One", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOXONE }, { 0x0f0d, 0x0067, "HORIPAD ONE", 0, XTYPE_XBOXONE }, { 0x0f0d, 0x0078, "Hori Real Arcade Pro V Kai Xbox One", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOXONE }, { 0x0f30, 0x010b, "Philips Recoil", 0, XTYPE_XBOX }, { 0x0f30, 0x0202, "Joytech Advanced Controller", 0, XTYPE_XBOX }, { 0x0f30, 0x8888, "BigBen XBMiniPad Controller", 0, XTYPE_XBOX }, { 0x102c, 0xff0c, "Joytech Wireless Advanced Controller", 0, XTYPE_XBOX }, { 0x11c9, 0x55f0, "Nacon GC-100XF", 0, XTYPE_XBOX360 }, { 0x12ab, 0x0004, "Honey Bee Xbox360 dancepad", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX360 }, { 0x12ab, 0x0301, "PDP AFTERGLOW AX.1", 0, XTYPE_XBOX360 }, { 0x12ab, 0x0303, "Mortal Kombat Klassic FightStick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x12ab, 0x8809, "Xbox DDR dancepad", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x1430, 0x4748, "RedOctane Guitar Hero X-plorer", 0, XTYPE_XBOX360 }, { 0x1430, 0x8888, "TX6500+ Dance Pad (first generation)", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x1430, 0xf801, "RedOctane Controller", 0, XTYPE_XBOX360 }, { 0x146b, 0x0601, "BigBen Interactive XBOX 360 Controller", 0, XTYPE_XBOX360 }, { 0x1532, 0x0037, "Razer Sabertooth", 0, XTYPE_XBOX360 }, { 0x1532, 0x0a00, "Razer Atrox Arcade Stick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOXONE }, { 0x1532, 0x0a03, "Razer Wildcat", 0, XTYPE_XBOXONE }, { 0x15e4, 0x3f00, "Power A Mini Pro Elite", 0, XTYPE_XBOX360 }, { 0x15e4, 0x3f0a, "Xbox Airflo wired controller", 0, XTYPE_XBOX360 }, { 0x15e4, 0x3f10, "Batarang Xbox 360 controller", 0, XTYPE_XBOX360 }, { 0x162e, 0xbeef, "Joytech Neo-Se Take2", 0, XTYPE_XBOX360 }, { 0x1689, 0xfd00, "Razer Onza Tournament Edition", 0, XTYPE_XBOX360 }, { 0x1689, 0xfd01, "Razer Onza Classic Edition", 0, XTYPE_XBOX360 }, { 0x1689, 0xfe00, "Razer Sabertooth", 0, XTYPE_XBOX360 }, { 0x1bad, 0x0002, "Harmonix Rock Band Guitar", 0, XTYPE_XBOX360 }, { 0x1bad, 0x0003, "Harmonix Rock Band Drumkit", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0x0130, "Ion Drum Rocker", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf016, "Mad Catz Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf018, "Mad Catz Street Fighter IV SE Fighting Stick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf019, "Mad Catz Brawlstick for Xbox 360", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf021, "Mad Cats Ghost Recon FS GamePad", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf023, "MLG Pro Circuit Controller (Xbox)", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf025, "Mad Catz Call Of Duty", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf027, "Mad Catz FPS Pro", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf028, "Street Fighter IV FightPad", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf02e, "Mad Catz Fightpad", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf030, "Mad Catz Xbox 360 MC2 MicroCon Racing Wheel", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf036, "Mad Catz MicroCon GamePad Pro", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf038, "Street Fighter IV FightStick TE", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf039, "Mad Catz MvC2 TE", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf03a, "Mad Catz SFxT Fightstick Pro", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf03d, "Street Fighter IV Arcade Stick TE - Chun Li", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf03e, "Mad Catz MLG FightStick TE", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf03f, "Mad Catz FightStick SoulCaliber", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf042, "Mad Catz FightStick TES+", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf080, "Mad Catz FightStick TE2", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf501, "HoriPad EX2 Turbo", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf502, "Hori Real Arcade Pro.VX SA", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf503, "Hori Fighting Stick VX", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf504, "Hori Real Arcade Pro. EX", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf505, "Hori Fighting Stick EX2B", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf506, "Hori Real Arcade Pro.EX Premium VLX", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf900, "Harmonix Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf901, "Gamestop Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf903, "Tron Xbox 360 controller", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf904, "PDP Versus Fighting Pad", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf906, "MortalKombat FightStick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xfa01, "MadCatz GamePad", 0, XTYPE_XBOX360 }, { 0x1bad, 0xfd00, "Razer Onza TE", 0, XTYPE_XBOX360 }, { 0x1bad, 0xfd01, "Razer Onza", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5000, "Razer Atrox Arcade Stick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x24c6, 0x5300, "PowerA MINI PROEX Controller", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5303, "Xbox Airflo wired controller", 0, XTYPE_XBOX360 }, { 0x24c6, 0x530a, "Xbox 360 Pro EX Controller", 0, XTYPE_XBOX360 }, { 0x24c6, 0x531a, "PowerA Pro Ex", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5397, "FUS1ON Tournament Controller", 0, XTYPE_XBOX360 }, { 0x24c6, 0x541a, "PowerA Xbox One Mini Wired Controller", 0, XTYPE_XBOXONE }, { 0x24c6, 0x542a, "Xbox ONE spectra", 0, XTYPE_XBOXONE }, { 0x24c6, 0x543a, "PowerA Xbox One wired controller", 0, XTYPE_XBOXONE }, { 0x24c6, 0x5500, "Hori XBOX 360 EX 2 with Turbo", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5501, "Hori Real Arcade Pro VX-SA", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5502, "Hori Fighting Stick VX Alt", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x24c6, 0x5503, "Hori Fighting Edge", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x24c6, 0x5506, "Hori SOULCALIBUR V Stick", 0, XTYPE_XBOX360 }, { 0x24c6, 0x550d, "Hori GEM Xbox controller", 0, XTYPE_XBOX360 }, { 0x24c6, 0x550e, "Hori Real Arcade Pro V Kai 360", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x24c6, 0x551a, "PowerA FUSION Pro Controller", 0, XTYPE_XBOXONE }, { 0x24c6, 0x561a, "PowerA FUSION Controller", 0, XTYPE_XBOXONE }, { 0x24c6, 0x5b00, "ThrustMaster Ferrari 458 Racing Wheel", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5b02, "Thrustmaster, Inc. GPX Controller", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5b03, "Thrustmaster Ferrari 458 Racing Wheel", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5d04, "Razer Sabertooth", 0, XTYPE_XBOX360 }, { 0x24c6, 0xfafe, "Rock Candy Gamepad for Xbox 360", 0, XTYPE_XBOX360 }, { 0x3767, 0x0101, "Fanatec Speedster 3 Forceshock Wheel", 0, XTYPE_XBOX }, { 0xffff, 0xffff, "Chinese-made Xbox Controller", 0, XTYPE_XBOX }, { 0x0000, 0x0000, "Generic X-Box pad", 0, XTYPE_UNKNOWN }
|
|
|
Post by jj0 on Jan 8, 2019 20:18:18 GMT
Cool! Thanks for reporting back. Nice that it works. I'm surprised you need to force loading with '-f'. I compiled it with the Modules.symvers from the Mini and on mine (fw 1_2_0-shield) the busybox insmod loads it OK. Regarding the LEDs, the C64Mini kernel doesn't have LED driver support enabled. I tried an xpad.ko with CONFIG_JOYSTICK_XPAD_FF=y and CONFIG_JOYSTICK_XPAD_LEDS=y but no /sys/class/leds/xpad0/... appeared. Maybe I can provide LED support as a module too. Ok, I'll try again with original insmod without -f. I only tried it with your kernel and assumed the rest;-) Most likely "modprobe" works as well then. AFAIK XPAD_FF provides Force Feedback support, depends on CONFIG_INPUT_FF_MEMLESS and is not needed. XPAD_LEDS depends on CONFIG_LEDS_CLASS according to Kconfig. I'v added led_core.ko and led_class.ko that are missing in the Mini's kernel an have compiled and tried various xpad sources and enabled CONFIG_JOYSTICK_XPAD_LEDS. Loading led_core.ko and led_class.ko allows xpad.ko to creat the /sys/class/leds/xpad0 structure, but echoing a number to brightness has no effect on the blinking 'X' on my 360 controller. The resulting modules are attached. Maybe you have better luck. Otherwise a piece of tape will have to do The controller kind of works, at least a fire button and the start button. But using the standard SDL gamecontrollerdb entry does not make it work, so there's some mapping to do. xpad-modules.zip (465.91 KB)
|
|
|
Post by darbyram on Jan 8, 2019 22:29:16 GMT
I suppose this should work with most Xbox controller's, as well as other gamepads as some use the xpad.ko driver? Yes, there are a lot of controllers defined in the sourcecode: { 0x0079, 0x18d4, "GPD Win 2 X-Box Controller", 0, XTYPE_XBOX360 }, { 0x044f, 0x0f00, "Thrustmaster Wheel", 0, XTYPE_XBOX }, { 0x044f, 0x0f03, "Thrustmaster Wheel", 0, XTYPE_XBOX }, { 0x044f, 0x0f07, "Thrustmaster, Inc. Controller", 0, XTYPE_XBOX }, { 0x044f, 0x0f10, "Thrustmaster Modena GT Wheel", 0, XTYPE_XBOX }, { 0x044f, 0xb326, "Thrustmaster Gamepad GP XID", 0, XTYPE_XBOX360 }, { 0x045e, 0x0202, "Microsoft X-Box pad v1 (US)", 0, XTYPE_XBOX }, { 0x045e, 0x0285, "Microsoft X-Box pad (Japan)", 0, XTYPE_XBOX }, { 0x045e, 0x0287, "Microsoft Xbox Controller S", 0, XTYPE_XBOX }, { 0x045e, 0x0288, "Microsoft Xbox Controller S v2", 0, XTYPE_XBOX }, { 0x045e, 0x0289, "Microsoft X-Box pad v2 (US)", 0, XTYPE_XBOX }, { 0x045e, 0x028e, "Microsoft X-Box 360 pad", 0, XTYPE_XBOX360 }, { 0x045e, 0x028f, "Microsoft X-Box 360 pad v2", 0, XTYPE_XBOX360 }, { 0x045e, 0x0291, "Xbox 360 Wireless Receiver (XBOX)", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX360W }, { 0x045e, 0x02d1, "Microsoft X-Box One pad", 0, XTYPE_XBOXONE }, { 0x045e, 0x02dd, "Microsoft X-Box One pad (Firmware 2015)", 0, XTYPE_XBOXONE }, { 0x045e, 0x02e3, "Microsoft X-Box One Elite pad", 0, XTYPE_XBOXONE }, { 0x045e, 0x02ea, "Microsoft X-Box One S pad", 0, XTYPE_XBOXONE }, { 0x2e24, 0x0652, "Hyperkin Duke X-Box One pad", 0, XTYPE_XBOXONE }, { 0x045e, 0x0719, "Xbox 360 Wireless Receiver", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX360W }, { 0x046d, 0xc21d, "Logitech Gamepad F310", 0, XTYPE_XBOX360 }, { 0x046d, 0xc21e, "Logitech Gamepad F510", 0, XTYPE_XBOX360 }, { 0x046d, 0xc21f, "Logitech Gamepad F710", 0, XTYPE_XBOX360 }, { 0x046d, 0xc242, "Logitech Chillstream Controller", 0, XTYPE_XBOX360 }, { 0x046d, 0xca84, "Logitech Xbox Cordless Controller", 0, XTYPE_XBOX }, { 0x046d, 0xca88, "Logitech Compact Controller for Xbox", 0, XTYPE_XBOX }, { 0x046d, 0xca8a, "Logitech Precision Vibration Feedback Wheel", 0, XTYPE_XBOX }, { 0x046d, 0xcaa3, "Logitech DriveFx Racing Wheel", 0, XTYPE_XBOX360 }, { 0x056e, 0x2004, "Elecom JC-U3613M", 0, XTYPE_XBOX360 }, { 0x05fd, 0x1007, "Mad Catz Controller (unverified)", 0, XTYPE_XBOX }, { 0x05fd, 0x107a, "InterAct 'PowerPad Pro' X-Box pad (Germany)", 0, XTYPE_XBOX }, { 0x05fe, 0x3030, "Chic Controller", 0, XTYPE_XBOX }, { 0x05fe, 0x3031, "Chic Controller", 0, XTYPE_XBOX }, { 0x062a, 0x0020, "Logic3 Xbox GamePad", 0, XTYPE_XBOX }, { 0x062a, 0x0033, "Competition Pro Steering Wheel", 0, XTYPE_XBOX }, { 0x06a3, 0x0200, "Saitek Racing Wheel", 0, XTYPE_XBOX }, { 0x06a3, 0x0201, "Saitek Adrenalin", 0, XTYPE_XBOX }, { 0x06a3, 0xf51a, "Saitek P3600", 0, XTYPE_XBOX360 }, { 0x0738, 0x4506, "Mad Catz 4506 Wireless Controller", 0, XTYPE_XBOX }, { 0x0738, 0x4516, "Mad Catz Control Pad", 0, XTYPE_XBOX }, { 0x0738, 0x4520, "Mad Catz Control Pad Pro", 0, XTYPE_XBOX }, { 0x0738, 0x4522, "Mad Catz LumiCON", 0, XTYPE_XBOX }, { 0x0738, 0x4526, "Mad Catz Control Pad Pro", 0, XTYPE_XBOX }, { 0x0738, 0x4530, "Mad Catz Universal MC2 Racing Wheel and Pedals", 0, XTYPE_XBOX }, { 0x0738, 0x4536, "Mad Catz MicroCON", 0, XTYPE_XBOX }, { 0x0738, 0x4540, "Mad Catz Beat Pad", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x0738, 0x4556, "Mad Catz Lynx Wireless Controller", 0, XTYPE_XBOX }, { 0x0738, 0x4586, "Mad Catz MicroCon Wireless Controller", 0, XTYPE_XBOX }, { 0x0738, 0x4588, "Mad Catz Blaster", 0, XTYPE_XBOX }, { 0x0738, 0x45ff, "Mad Catz Beat Pad (w/ Handle)", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x0738, 0x4716, "Mad Catz Wired Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x0738, 0x4718, "Mad Catz Street Fighter IV FightStick SE", 0, XTYPE_XBOX360 }, { 0x0738, 0x4726, "Mad Catz Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x0738, 0x4728, "Mad Catz Street Fighter IV FightPad", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0738, 0x4736, "Mad Catz MicroCon Gamepad", 0, XTYPE_XBOX360 }, { 0x0738, 0x4738, "Mad Catz Wired Xbox 360 Controller (SFIV)", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0738, 0x4740, "Mad Catz Beat Pad", 0, XTYPE_XBOX360 }, { 0x0738, 0x4743, "Mad Catz Beat Pad Pro", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x0738, 0x4758, "Mad Catz Arcade Game Stick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0738, 0x4a01, "Mad Catz FightStick TE 2", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOXONE }, { 0x0738, 0x6040, "Mad Catz Beat Pad Pro", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x0738, 0x9871, "Mad Catz Portable Drum", 0, XTYPE_XBOX360 }, { 0x0738, 0xb726, "Mad Catz Xbox controller - MW2", 0, XTYPE_XBOX360 }, { 0x0738, 0xb738, "Mad Catz MVC2TE Stick 2", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0738, 0xbeef, "Mad Catz JOYTECH NEO SE Advanced GamePad", XTYPE_XBOX360 }, { 0x0738, 0xcb02, "Saitek Cyborg Rumble Pad - PC/Xbox 360", 0, XTYPE_XBOX360 }, { 0x0738, 0xcb03, "Saitek P3200 Rumble Pad - PC/Xbox 360", 0, XTYPE_XBOX360 }, { 0x0738, 0xcb29, "Saitek Aviator Stick AV8R02", 0, XTYPE_XBOX360 }, { 0x0738, 0xf738, "Super SFIV FightStick TE S", 0, XTYPE_XBOX360 }, { 0x07ff, 0xffff, "Mad Catz GamePad", 0, XTYPE_XBOX360 }, { 0x0c12, 0x0005, "Intec wireless", 0, XTYPE_XBOX }, { 0x0c12, 0x8801, "Nyko Xbox Controller", 0, XTYPE_XBOX }, { 0x0c12, 0x8802, "Zeroplus Xbox Controller", 0, XTYPE_XBOX }, { 0x0c12, 0x8809, "RedOctane Xbox Dance Pad", DANCEPAD_MAP_CONFIG, XTYPE_XBOX }, { 0x0c12, 0x880a, "Pelican Eclipse PL-2023", 0, XTYPE_XBOX }, { 0x0c12, 0x8810, "Zeroplus Xbox Controller", 0, XTYPE_XBOX }, { 0x0c12, 0x9902, "HAMA VibraX - *FAULTY HARDWARE*", 0, XTYPE_XBOX }, { 0x0d2f, 0x0002, "Andamiro Pump It Up pad", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x0e4c, 0x1097, "Radica Gamester Controller", 0, XTYPE_XBOX }, { 0x0e4c, 0x1103, "Radica Gamester Reflex", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX }, { 0x0e4c, 0x2390, "Radica Games Jtech Controller", 0, XTYPE_XBOX }, { 0x0e4c, 0x3510, "Radica Gamester", 0, XTYPE_XBOX }, { 0x0e6f, 0x0003, "Logic3 Freebird wireless Controller", 0, XTYPE_XBOX }, { 0x0e6f, 0x0005, "Eclipse wireless Controller", 0, XTYPE_XBOX }, { 0x0e6f, 0x0006, "Edge wireless Controller", 0, XTYPE_XBOX }, { 0x0e6f, 0x0008, "After Glow Pro Controller", 0, XTYPE_XBOX }, { 0x0e6f, 0x0105, "HSM3 Xbox360 dancepad", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0e6f, 0x0113, "Afterglow AX.1 Gamepad for Xbox 360", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x011f, "Rock Candy Gamepad Wired Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0131, "PDP EA Sports Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0133, "Xbox 360 Wired Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0139, "Afterglow Prismatic Xbox One Wired Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02b3, "Afterglow Prismatic Xbox One Wired Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02b8, "Afterglow Prismatic Wired Controller for Xbox One", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x013a, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0146, "Rock Candy Wired Controller for Xbox One", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0147, "PDP Marvel Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x015c, "PDP Xbox One Arcade Stick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOXONE }, { 0x0e6f, 0x0161, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0162, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0163, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a0, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a1, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a7, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a8, "PDP Xbox One Controller", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0164, "PDP Battlefield One", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0165, "PDP Titanfall 2", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0201, "Pelican PL-3601 'TSZ' Wired Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0213, "Afterglow Gamepad for Xbox 360", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x021f, "Rock Candy Gamepad for Xbox 360", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0246, "Rock Candy Gamepad for Xbox One 2015", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02ab, "PDP Controller for Xbox One", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a2, "PDP Wired Controller for Xbox One - Crimson Red", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a4, "PDP Wired Controller for Xbox One - Stealth Series", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02a6, "PDP Wired Controller for Xbox One - Camo Series", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x02ad, "PDP Wired Controller for Xbox One - Stealth Series", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0301, "Logic3 Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0346, "Rock Candy Gamepad for Xbox One 2016", 0, XTYPE_XBOXONE }, { 0x0e6f, 0x0401, "Logic3 Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0413, "Afterglow AX.1 Gamepad for Xbox 360", 0, XTYPE_XBOX360 }, { 0x0e6f, 0x0501, "PDP Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x0e6f, 0xf900, "PDP Afterglow AX.1", 0, XTYPE_XBOX360 }, { 0x0e8f, 0x0201, "SmartJoy Frag Xpad/PS2 adaptor", 0, XTYPE_XBOX }, { 0x0e8f, 0x3008, "Generic xbox control (dealextreme)", 0, XTYPE_XBOX }, { 0x0f0d, 0x000a, "Hori Co. DOA4 FightStick", 0, XTYPE_XBOX360 }, { 0x0f0d, 0x000c, "Hori PadEX Turbo", 0, XTYPE_XBOX360 }, { 0x0f0d, 0x000d, "Hori Fighting Stick EX2", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0f0d, 0x0016, "Hori Real Arcade Pro.EX", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0f0d, 0x001b, "Hori Real Arcade Pro VX", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x0f0d, 0x0063, "Hori Real Arcade Pro Hayabusa (USA) Xbox One", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOXONE }, { 0x0f0d, 0x0067, "HORIPAD ONE", 0, XTYPE_XBOXONE }, { 0x0f0d, 0x0078, "Hori Real Arcade Pro V Kai Xbox One", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOXONE }, { 0x0f30, 0x010b, "Philips Recoil", 0, XTYPE_XBOX }, { 0x0f30, 0x0202, "Joytech Advanced Controller", 0, XTYPE_XBOX }, { 0x0f30, 0x8888, "BigBen XBMiniPad Controller", 0, XTYPE_XBOX }, { 0x102c, 0xff0c, "Joytech Wireless Advanced Controller", 0, XTYPE_XBOX }, { 0x11c9, 0x55f0, "Nacon GC-100XF", 0, XTYPE_XBOX360 }, { 0x12ab, 0x0004, "Honey Bee Xbox360 dancepad", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX360 }, { 0x12ab, 0x0301, "PDP AFTERGLOW AX.1", 0, XTYPE_XBOX360 }, { 0x12ab, 0x0303, "Mortal Kombat Klassic FightStick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x12ab, 0x8809, "Xbox DDR dancepad", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x1430, 0x4748, "RedOctane Guitar Hero X-plorer", 0, XTYPE_XBOX360 }, { 0x1430, 0x8888, "TX6500+ Dance Pad (first generation)", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX }, { 0x1430, 0xf801, "RedOctane Controller", 0, XTYPE_XBOX360 }, { 0x146b, 0x0601, "BigBen Interactive XBOX 360 Controller", 0, XTYPE_XBOX360 }, { 0x1532, 0x0037, "Razer Sabertooth", 0, XTYPE_XBOX360 }, { 0x1532, 0x0a00, "Razer Atrox Arcade Stick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOXONE }, { 0x1532, 0x0a03, "Razer Wildcat", 0, XTYPE_XBOXONE }, { 0x15e4, 0x3f00, "Power A Mini Pro Elite", 0, XTYPE_XBOX360 }, { 0x15e4, 0x3f0a, "Xbox Airflo wired controller", 0, XTYPE_XBOX360 }, { 0x15e4, 0x3f10, "Batarang Xbox 360 controller", 0, XTYPE_XBOX360 }, { 0x162e, 0xbeef, "Joytech Neo-Se Take2", 0, XTYPE_XBOX360 }, { 0x1689, 0xfd00, "Razer Onza Tournament Edition", 0, XTYPE_XBOX360 }, { 0x1689, 0xfd01, "Razer Onza Classic Edition", 0, XTYPE_XBOX360 }, { 0x1689, 0xfe00, "Razer Sabertooth", 0, XTYPE_XBOX360 }, { 0x1bad, 0x0002, "Harmonix Rock Band Guitar", 0, XTYPE_XBOX360 }, { 0x1bad, 0x0003, "Harmonix Rock Band Drumkit", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0x0130, "Ion Drum Rocker", MAP_DPAD_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf016, "Mad Catz Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf018, "Mad Catz Street Fighter IV SE Fighting Stick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf019, "Mad Catz Brawlstick for Xbox 360", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf021, "Mad Cats Ghost Recon FS GamePad", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf023, "MLG Pro Circuit Controller (Xbox)", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf025, "Mad Catz Call Of Duty", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf027, "Mad Catz FPS Pro", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf028, "Street Fighter IV FightPad", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf02e, "Mad Catz Fightpad", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf030, "Mad Catz Xbox 360 MC2 MicroCon Racing Wheel", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf036, "Mad Catz MicroCon GamePad Pro", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf038, "Street Fighter IV FightStick TE", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf039, "Mad Catz MvC2 TE", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf03a, "Mad Catz SFxT Fightstick Pro", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf03d, "Street Fighter IV Arcade Stick TE - Chun Li", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf03e, "Mad Catz MLG FightStick TE", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf03f, "Mad Catz FightStick SoulCaliber", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf042, "Mad Catz FightStick TES+", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf080, "Mad Catz FightStick TE2", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf501, "HoriPad EX2 Turbo", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf502, "Hori Real Arcade Pro.VX SA", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf503, "Hori Fighting Stick VX", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf504, "Hori Real Arcade Pro. EX", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf505, "Hori Fighting Stick EX2B", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xf506, "Hori Real Arcade Pro.EX Premium VLX", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf900, "Harmonix Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf901, "Gamestop Xbox 360 Controller", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf903, "Tron Xbox 360 controller", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf904, "PDP Versus Fighting Pad", 0, XTYPE_XBOX360 }, { 0x1bad, 0xf906, "MortalKombat FightStick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x1bad, 0xfa01, "MadCatz GamePad", 0, XTYPE_XBOX360 }, { 0x1bad, 0xfd00, "Razer Onza TE", 0, XTYPE_XBOX360 }, { 0x1bad, 0xfd01, "Razer Onza", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5000, "Razer Atrox Arcade Stick", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x24c6, 0x5300, "PowerA MINI PROEX Controller", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5303, "Xbox Airflo wired controller", 0, XTYPE_XBOX360 }, { 0x24c6, 0x530a, "Xbox 360 Pro EX Controller", 0, XTYPE_XBOX360 }, { 0x24c6, 0x531a, "PowerA Pro Ex", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5397, "FUS1ON Tournament Controller", 0, XTYPE_XBOX360 }, { 0x24c6, 0x541a, "PowerA Xbox One Mini Wired Controller", 0, XTYPE_XBOXONE }, { 0x24c6, 0x542a, "Xbox ONE spectra", 0, XTYPE_XBOXONE }, { 0x24c6, 0x543a, "PowerA Xbox One wired controller", 0, XTYPE_XBOXONE }, { 0x24c6, 0x5500, "Hori XBOX 360 EX 2 with Turbo", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5501, "Hori Real Arcade Pro VX-SA", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5502, "Hori Fighting Stick VX Alt", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x24c6, 0x5503, "Hori Fighting Edge", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x24c6, 0x5506, "Hori SOULCALIBUR V Stick", 0, XTYPE_XBOX360 }, { 0x24c6, 0x550d, "Hori GEM Xbox controller", 0, XTYPE_XBOX360 }, { 0x24c6, 0x550e, "Hori Real Arcade Pro V Kai 360", MAP_TRIGGERS_TO_BUTTONS, XTYPE_XBOX360 }, { 0x24c6, 0x551a, "PowerA FUSION Pro Controller", 0, XTYPE_XBOXONE }, { 0x24c6, 0x561a, "PowerA FUSION Controller", 0, XTYPE_XBOXONE }, { 0x24c6, 0x5b00, "ThrustMaster Ferrari 458 Racing Wheel", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5b02, "Thrustmaster, Inc. GPX Controller", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5b03, "Thrustmaster Ferrari 458 Racing Wheel", 0, XTYPE_XBOX360 }, { 0x24c6, 0x5d04, "Razer Sabertooth", 0, XTYPE_XBOX360 }, { 0x24c6, 0xfafe, "Rock Candy Gamepad for Xbox 360", 0, XTYPE_XBOX360 }, { 0x3767, 0x0101, "Fanatec Speedster 3 Forceshock Wheel", 0, XTYPE_XBOX }, { 0xffff, 0xffff, "Chinese-made Xbox Controller", 0, XTYPE_XBOX }, { 0x0000, 0x0000, "Generic X-Box pad", 0, XTYPE_UNKNOWN }
Cool, just need to work out how to do it.
|
|
|
Post by MASHtm on Jan 9, 2019 0:27:00 GMT
I'v added led_core.ko and led_class.ko that are missing in the Mini's kernel an have compiled and tried various xpad sources and enabled CONFIG_JOYSTICK_XPAD_LEDS. Loading led_core.ko and led_class.ko allows xpad.ko to creat the /sys/class/leds/xpad0 structure, but echoing a number to brightness has no effect on the blinking 'X' on my 360 controller. The resulting modules are attached. Maybe you have better luck. Otherwise a piece of tape will have to do The controller kind of works, at least a fire button and the start button. But using the standard SDL gamecontrollerdb entry does not make it work, so there's some mapping to do. Same result here. Could not set the LED as well. In the end I used the latest git version. I noticed that led-core module triggers a "unknown license: kernel tainted" message? Original insmod works without -f.
On my pad I found every function of the original joystick, but there is room for improvement;-)
LB = Fire (primary button) BACK = B3 (- - x -) START = B4 (- - - x) A = B1 (x - - -) X = Small Shoulder Left Y = Small Shoulder Right Since my pad is defined as...
030000005e0400001907000000010000,X360 Wireless Controller,a:b0,b:b1,back:b6,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,platform:Linux, ... I'll try to remap the buttons in the next days.
|
|
|
Post by jj0 on Jan 10, 2019 5:45:26 GMT
I'v added led_core.ko and led_class.ko that are missing in the Mini's kernel an have compiled and tried various xpad sources and enabled CONFIG_JOYSTICK_XPAD_LEDS. Loading led_core.ko and led_class.ko allows xpad.ko to creat the /sys/class/leds/xpad0 structure, but echoing a number to brightness has no effect on the blinking 'X' on my 360 controller. The resulting modules are attached. Maybe you have better luck. Otherwise a piece of tape will have to do The controller kind of works, at least a fire button and the start button. But using the standard SDL gamecontrollerdb entry does not make it work, so there's some mapping to do. Same result here. Could not set the LED as well. In the end I used the latest git version. I noticed that led-core module triggers a "unknown license: kernel tainted" message? Original insmod works without -f.
On my pad I found every function of the original joystick, but there is room for improvement;-)
LB = Fire (primary button) BACK = B3 (- - x -) START = B4 (- - - x) A = B1 (x - - -) X = Small Shoulder Left Y = Small Shoulder Right Since my pad is defined as...
030000005e0400001907000000010000,X360 Wireless Controller,a:b0,b:b1,back:b6,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,platform:Linux, ... I'll try to remap the buttons in the next days.
My pad's ID is 030000005e040000a102000007010000, so slightly different from yours. With your definition I still only get the fire button mapped to 'Y' and right trigger. So I need to do some more experimenting. It's a good thing I like my Competition Pro better Regarding the 'kernel tainted' message, that's just the kernel telling you that the led_core.ko module doesn't declare itself as GPL. The code in led_core normally is part of the kernel if CONFIG_NEW_LEDS=y, but as the C64Mini's CONFIG_NEW_LEDS is 'not set' this code isn't included. I forced this to be compiled as a module so it could be loaded on the Mini. However as it isn't actually written as a module it is missing the declaration as GPL. It fdoesn't affect the actual services/functions it provides. Currently the best option is to use one of the 'without LED' modules and not load the led_core nor the led_class. I'm not sure why the LED's don't work, form some debugging I (think I) can see the xpad.ko responding to changes in /sys/class/leds/xpad0/brightness and calling the routine to send data to the Wireless USB adapter. However nothing happens. Still, the main function seems to work OK, so it's a minor issue. I might look into it more. Does the driver also work if you power off and then power on the pad, and also if you remove and then reinsert the USB adapter?
|
|
|
Post by jj0 on Jan 13, 2019 11:25:52 GMT
Same result here. Could not set the LED as well. In the end I used the latest git version. I noticed that led-core module triggers a "unknown license: kernel tainted" message? Original insmod works without -f.
On my pad I found every function of the original joystick, but there is room for improvement;-)
LB = Fire (primary button) BACK = B3 (- - x -) START = B4 (- - - x) A = B1 (x - - -) X = Small Shoulder Left Y = Small Shoulder Right Since my pad is defined as...
030000005e0400001907000000010000,X360 Wireless Controller,a:b0,b:b1,back:b6,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,platform:Linux, ... I'll try to remap the buttons in the next days.
My pad's ID is 030000005e040000a102000007010000, so slightly different from yours. With your definition I still only get the fire button mapped to 'Y' and right trigger. So I need to do some more experimenting. It's a good thing I like my Competition Pro better Regarding the 'kernel tainted' message, that's just the kernel telling you that the led_core.ko module doesn't declare itself as GPL. The code in led_core normally is part of the kernel if CONFIG_NEW_LEDS=y, but as the C64Mini's CONFIG_NEW_LEDS is 'not set' this code isn't included. I forced this to be compiled as a module so it could be loaded on the Mini. However as it isn't actually written as a module it is missing the declaration as GPL. It fdoesn't affect the actual services/functions it provides. Currently the best option is to use one of the 'without LED' modules and not load the led_core nor the led_class. I'm not sure why the LED's don't work, form some debugging I (think I) can see the xpad.ko responding to changes in /sys/class/leds/xpad0/brightness and calling the routine to send data to the Wireless USB adapter. However nothing happens. Still, the main function seems to work OK, so it's a minor issue. I might look into it more. Does the driver also work if you power off and then power on the pad, and also if you remove and then reinsert the USB adapter? Here's an updated version with full LED support. Works fine with powering the pad on and off, but if you remove the USB receiver the Mini will hang.
|
|
|
Post by MASHtm on Jan 16, 2019 0:50:56 GMT
thanks so much for your efforts! I'm a little bit short of time currently, but I'll try in the next days.
|
|
|
Post by MASHtm on Jan 16, 2019 20:39:43 GMT
I was able to finish this today. Your new modules work perfectly and I changed the mapping of my Controller as follows:
-030000005e040000a102000000010000,X360 Wireless Controller,a:b0,b:b1,back:b6,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,platform:Linux, +030000005e040000a102000000010000,X360 Wireless Controller,a:b2,b:b6,back:b3,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b0,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b1,x:b5,y:b4,platform:Linux, ... yes, I got the ID wrong in my first post:)
The resulting mapping is:
fire left => A fire right => Start (not needed IMO) left small => left shoulder right small => right shoulder - - - X => B X - - - => X - - X - => Y - X - - => BACK
Most Games use "A" as Fire. Some use the right shoulder and A for something different. Don't know why. C64 always used only one button IIRC.
Again thanks for providing the modules!
|
|
|
Post by jj0 on Jan 16, 2019 21:33:18 GMT
I was able to finish this today. Your new modules work perfectly and I changed the mapping of my Controller as follows:
-030000005e040000a102000000010000,X360 Wireless Controller,a:b0,b:b1,back:b6,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,platform:Linux, +030000005e040000a102000000010000,X360 Wireless Controller,a:b2,b:b6,back:b3,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b0,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b1,x:b5,y:b4,platform:Linux, ... yes, I got the ID wrong in my first post:)
The resulting mapping is:
fire left => A fire right => Start (not needed IMO) left small => left shoulder right small => right shoulder - - - X => B X - - - => X - - X - => Y - X - - => BACK
Most Games use "A" as Fire. Some use the right shoulder and A for something different. Don't know why. C64 always used only one button IIRC.Â
Again thanks for providing the modules!
You're welcome, I will try your definition when I finally get around to actually playing a game!
|
|
|
Post by kugelblitz on Jan 27, 2019 20:43:31 GMT
Sorry for asking, but how would I permanently put this into my Mini? I understand that on FEL boot I can load these with commandline Tools. But how would I install them to the Mini?
(Ideally there will be another script for the USB Scripting Method from jj0 so I could just install via USB and FEL boot once).
Thank you!
|
|
|
Post by jj0 on Jan 28, 2019 10:21:57 GMT
Sorry for asking, but how would I permanently put this into my Mini? I understand that on FEL boot I can load these with commandline Tools. But how would I install them to the Mini? (Ideally there will be another script for the USB Scripting Method from jj0 so I could just install via USB and FEL boot once). Thank you! No script at the moment, but maybe this will inspire you Manual install: - Copy the 3 modules (led-core.ko, led-class.ko, xpad.ko) to the rootfs. E.g. to folder /opt, or /lib/modules/3.4.39 where the other modules are.
- Create a startup script in /etc/init.d to load the modules at startup (in this case I use /lib/modules/3.4.39):
cat >/etc/init.d/S95xpad #!/bin/sh echo "Loading xpad and led drivers" insmod /lib/modules/3.4.39/led-core.ko insmod /lib/modules/3.4.39/led-class.ko insmod /lib/modules/3.4.39/xpad.ko <CTRL-D> chmod +x /etc/init.d/S95xpad reboot
This should load the drivers every time you start the Mini.
|
|
|
Post by kugelblitz on Jan 28, 2019 13:25:04 GMT
IT WORKS!
Would like some different mapping though, but I can handle this myself. I am thinking of writing a script that does these steps automatically (including copying an updated controllerdb).
|
|
|
Post by kugelblitz on Jan 29, 2019 1:04:57 GMT
I was able to finish this today. Your new modules work perfectly and I changed the mapping of my Controller as follows:
-030000005e040000a102000000010000,X360 Wireless Controller,a:b0,b:b1,back:b6,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,platform:Linux, +030000005e040000a102000000010000,X360 Wireless Controller,a:b2,b:b6,back:b3,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b0,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b1,x:b5,y:b4,platform:Linux, ... yes, I got the ID wrong in my first post:)
The resulting mapping is:
fire left => A fire right => Start (not needed IMO) left small => left shoulder right small => right shoulder - - - X => B X - - - => X - - X - => Y - X - - => BACK
Most Games use "A" as Fire. Some use the right shoulder and A for something different. Don't know why. C64 always used only one button IIRC. Again thanks for providing the modules!
So the mapping in the C64MINI code is pure Insanity. I had to reverse engineer what they are doing to write proper mappings for the Wireless 360 Controller that REALLY work. The map I am giving you here is what I think is a logical "works always" map: A (Green) Maps to Big Fire Left B (Red) Maps to Big Fire Right X (Blue) Maps to Triangle Left Y (Yellow) Maps to Triangle Right Back (left to SilverGuide) Maps to A (1st Small Button) SilverGuide Maps to B (2nd Small Button) Start (right to SilverGuide) Maps to C (3rd Small Button) Right Shoulder Maps to MENU button This works for me because the three Buttons in the middle of the Controller now are in the same order as the three small Buttons. Button 2 (the Guide) is never used in the UI or Virtual Keyboard. These mappings now work everywhere, map correctly to every CJM file and work correctly with the Virtual Keyboard.If you read the mappings, they do not make obvious sense - because inside the Code in the C64Mini the assignments are used illogically. I had to map from the Mini Joystick to internal functions to Xpad to actual Buttons (and Xpad uses DIFFERENT button numbers than Windows!). The Mini crosses B3 and B2 and uses the lefttrigger/righttrigger assignments instead of A and B. Quite a puzzle! 030000005e0400001907000000010000,X360 Wireless Controller,a:b6,b:b8,back:b7,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,start:b5,lefttrigger:b0,leftx:a0,lefty:a1,righttrigger:b1,x:b3,y:b2,platform:Linux,
Included is a gamescontroller.db file WITH ONLY THE XBOX WIRELESS ADAPTER LINES - you Need to add them to your .db. Most likely you can add the same mappings to any Xbox 360 compatible wired Controller as well (NOT XBOX ONE CONTROLLERS!)
Also included is the correct button assignment graphic. If you want to set any button differently (for example, have A on Left Shoulder instead of Start), do as follows: Check in the graphic which button is used (in this case Back is B6 and the Mini interprets Back as A), look for B6 in the mapping (it is to a:) then change the B6 there to B4 (which is the correct button for the left shoulder in the Xpad driver).
Because everbody most likely wants different mappings AND I am unsure if future firmwares come with a different *db.txt, I am refraining from building and Posting scripts that copy all this automatically.
Feel free to include all this in any Wiki, scripting project or whatever else.
Many thanks to jj0 for all the great work this simple map is based on.
|
|
|
Post by kugelblitz on Feb 3, 2020 14:36:39 GMT
Just a short update on this because I finally updated my Mini from 1.2 to 1.3.x. Of course 1.3.x has a new controller.db and of course it is totally rubbish if you use Xbox 360 controllers. They are now detected but they do not use a proper mapping, so buttons are just insane. You can take the controller.db from my year-old-posting and apply it (via jj0s excellent file manager!) if you want to use Xbox 360 controllers on your Mini (or Maxi). See article above this one or in quotes here on what I did. Thanks to all people providing the tools to make all this possible! I was able to finish this today. Your new modules work perfectly and I changed the mapping of my Controller as follows:
-030000005e040000a102000000010000,X360 Wireless Controller,a:b0,b:b1,back:b6,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,platform:Linux, +030000005e040000a102000000010000,X360 Wireless Controller,a:b2,b:b6,back:b3,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b0,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b1,x:b5,y:b4,platform:Linux, ... yes, I got the ID wrong in my first post:)
The resulting mapping is:
fire left => A fire right => Start (not needed IMO) left small => left shoulder right small => right shoulder - - - X => B X - - - => X - - X - => Y - X - - => BACK
Most Games use "A" as Fire. Some use the right shoulder and A for something different. Don't know why. C64 always used only one button IIRC. Again thanks for providing the modules!
So the mapping in the C64MINI code is pure Insanity. I had to reverse engineer what they are doing to write proper mappings for the Wireless 360 Controller that REALLY work. The map I am giving you here is what I think is a logical "works always" map: A (Green) Maps to Big Fire Left B (Red) Maps to Big Fire Right X (Blue) Maps to Triangle Left Y (Yellow) Maps to Triangle Right Back (left to SilverGuide) Maps to A (1st Small Button) SilverGuide Maps to B (2nd Small Button) Start (right to SilverGuide) Maps to C (3rd Small Button) Right Shoulder Maps to MENU button This works for me because the three Buttons in the middle of the Controller now are in the same order as the three small Buttons. Button 2 (the Guide) is never used in the UI or Virtual Keyboard. These mappings now work everywhere, map correctly to every CJM file and work correctly with the Virtual Keyboard.If you read the mappings, they do not make obvious sense - because inside the Code in the C64Mini the assignments are used illogically. I had to map from the Mini Joystick to internal functions to Xpad to actual Buttons (and Xpad uses DIFFERENT button numbers than Windows!). The Mini crosses B3 and B2 and uses the lefttrigger/righttrigger assignments instead of A and B. Quite a puzzle! 030000005e0400001907000000010000,X360 Wireless Controller,a:b6,b:b8,back:b7,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,start:b5,lefttrigger:b0,leftx:a0,lefty:a1,righttrigger:b1,x:b3,y:b2,platform:Linux,
Included is a gamescontroller.db file WITH ONLY THE XBOX WIRELESS ADAPTER LINES - you Need to add them to your .db. Most likely you can add the same mappings to any Xbox 360 compatible wired Controller as well (NOT XBOX ONE CONTROLLERS!)
Also included is the correct button assignment graphic. If you want to set any button differently (for example, have A on Left Shoulder instead of Start), do as follows: Check in the graphic which button is used (in this case Back is B6 and the Mini interprets Back as A), look for B6 in the mapping (it is to a:) then change the B6 there to B4 (which is the correct button for the left shoulder in the Xpad driver).
Because everbody most likely wants different mappings AND I am unsure if future firmwares come with a different *db.txt, I am refraining from building and Posting scripts that copy all this automatically.
Feel free to include all this in any Wiki, scripting project or whatever else.
Many thanks to jj0 for all the great work this simple map is based on.
|
|
|
Post by kugelblitz on Nov 12, 2020 22:02:35 GMT
Good evening, jj0 - I am trying to install the xpad drivers to the C64 MAXI instead of the Mini but can't get it to work. When I manually try the insmod commands, I am getting an "invalid module format" error. Any idea what I am doing wrong? Thanks, Boris Sorry for asking, but how would I permanently put this into my Mini? I understand that on FEL boot I can load these with commandline Tools. But how would I install them to the Mini? (Ideally there will be another script for the USB Scripting Method from jj0 so I could just install via USB and FEL boot once). Thank you! No script at the moment, but maybe this will inspire you Manual install: - Copy the 3 modules (led-core.ko, led-class.ko, xpad.ko) to the rootfs. E.g. to folder /opt, or /lib/modules/3.4.39 where the other modules are.
- Create a startup script in /etc/init.d to load the modules at startup (in this case I use /lib/modules/3.4.39):
cat >/etc/init.d/S95xpad #!/bin/sh echo "Loading xpad and led drivers" insmod /lib/modules/3.4.39/led-core.ko insmod /lib/modules/3.4.39/led-class.ko insmod /lib/modules/3.4.39/xpad.ko <CTRL-D> chmod +x /etc/init.d/S95xpad reboot
This should load the drivers every time you start the Mini.
|
|
|
Post by jj0 on Nov 13, 2020 10:58:09 GMT
Good evening, jj0 - I am trying to install the xpad drivers to the C64 MAXI instead of the Mini but can't get it to work. When I manually try the insmod commands, I am getting an "invalid module format" error. Any idea what I am doing wrong? Thanks, Boris The issue is that the Maxi uses a different SoC/CPU (Allwinner H3) compared to the Mini (Allwinner A20). This means they also use different Linux kernels so the kernel modules for the Mini are not compatible with the Maxi. They would need to be recompiled specifically with the SDK/kernel source and kernel configuration of the Maxi, but we do not have that SDK/kernel source nor kernel configuration. I've had some hit and miss results compiling modules using an Allwinner SDK for the Orange Pi or Nano Pi, some modules work but some (notably USB2Ethernet adapter support) just crash. I'll try to compile the x360 modules and see if they work.
|
|
|
Post by kugelblitz on Nov 13, 2020 12:21:58 GMT
Good evening, jj0 - I am trying to install the xpad drivers to the C64 MAXI instead of the Mini but can't get it to work. When I manually try the insmod commands, I am getting an "invalid module format" error. Any idea what I am doing wrong? Thanks, Boris The issue is that the Maxi uses a different SoC/CPU (Allwinner H3) compared to the Mini (Allwinner A20). This means they also use different Linux kernels so the kernel modules for the Mini are not compatible with the Maxi. They would need to be recompiled specifically with the SDK/kernel source and kernel configuration of the Maxi, but we do not have that SDK/kernel source nor kernel configuration. I've had some hit and miss results compiling modules using an Allwinner SDK for the Orange Pi or Nano Pi, some modules work but some (notably USB2Ethernet adapter support) just crash. I'll try to compile the x360 modules and see if they work. Of course... :-( Thanks for trying. I'll also see if somebody compiled them and has binaries on the web.
|
|
|
Post by spannernick on Nov 13, 2020 12:42:37 GMT
I have a wired Xbox 360 controller (I sometimes use it on my PC but most of the time I use my PS4 controller cause it has a soundcard built in to it so I can use headphones with it, and I can get it to emulate a Xbox 360 Controller) and added it to PCU gamecontollerdb.txt cause it never had it but I never tested yet, have to try it today, BTW how are you making the GUID mapping strings, I use SDL2 Gamepad Tool on Windows...? My Xbox wired don't work... LEDs are just flashing. When I connect it, it says.. and has no GUID number comes up like the other controllers I connect to THEC64 Maxi, its the number that come up like `0003/.../005` so you use that to make the GUID from. [ 112.130442] usb 3-1.2: new full-speed USB device number 6 using sunxi-ehci
so I am guessing this needs a driver in the kernal to work too, it properly works the same as the wireless version of the Xbox 360 controller but has the USB part all built into the controller. The Xbox Controller GUID Mapping sting is added to the gamecontollerdb.txt file cause that what's included in the SDL database file, don't mean the controller will work with THEC64 at all cause it might need a driver in its kernal to work(We need Source Code C64OSS v1.4.2 now and it has to be complete, RGL.. ), so the wired version of the 360 controller is not supported too. Well it only works on Windows cause it has a driver for the controller to work, One time I had a problem with it working on the PC cause windows couldn't load the driver for it so the controller stopped working. I had to restart the PC then it worked again, some times that happens if I plug it in after the PC has started so if I go to use it now I make sure it plugged in first before starting my PC. The XBOX 360 Controller can make itself Player 1 or player 2, that what the LEDs are for, you can use 4 XBOX 360 controllers on the 360 or PC, it has 4 LEDs on the controller and they change if you have another controller plugged in so if I have my PS4 Controller(I can get it to emulate a XBOX 360 Controller using Input Mapper(DS4Windows or use Steam) plugged in thats Player 1 so Xbox 360 controller becomes play 2 so the top right LED comes on saying its player 2. I have the same problem with my arcade Logic3 Tri Format Arcade stick that has 3 connectors on it, USB, Xbox Original and PS One(might be PS2) connectors, it works fine on the PC but nothing on THEC64 Maxi, it has a GUID on windows but not on Linux so missing the driver(in the kernal) it needs to work with it. This is a video about the arcade stick...
|
|
|
Post by kugelblitz on Nov 13, 2020 15:08:46 GMT
Yes, that's why you need the driver because the controller can be selected to player 1-4. Which actually works well with Vice on my PC, I can set up controller 3 and 4 on the userport and play 4 player games. Most likely that will not work on TheC64.
For the GUID mapping, I started with the SDL tool but also analysed what commands the TheC64 sticks send. And then I draw a large matrix and figured it out. There is a post about this earlier in the thread.
|
|
|
Post by spannernick on Nov 13, 2020 16:19:04 GMT
If you make a script for this I can add it to PCUAE and PCUME if you like..? and only run it if it sees its a THEC64 Mini PCU is running on so it will not run it on THEC64 Maxi or THE VIC 20...? And when it does come available for THEC64 Maxi/THE VIC 20 I will be able to get it to run 2 different scripts depending on what machine your running PCU on so it will only run one script ... Oh just seen the other post by jj0, ok thats is a start-up script, I can do it so PCUAE copies all the files over to the firmware for you so you will not need to do anything at all, and it will only do it once then reboot. It will be in a folder in Options called `XPAD_ XBox_360_Contoller_for_Mini` and it will check if its running on the Mini if its running on a maxi it will not copy the XPad files over so it will only work on THEC64 Mini, and when THEC64 Maxi version comes out I will do the same.. wow, never ever was me making scripts like this months ago..
|
|
|
Post by kugelblitz on Nov 16, 2020 8:28:08 GMT
Good evening, jj0 - I am trying to install the xpad drivers to the C64 MAXI instead of the Mini but can't get it to work. When I manually try the insmod commands, I am getting an "invalid module format" error. Any idea what I am doing wrong? Thanks, Boris The issue is that the Maxi uses a different SoC/CPU (Allwinner H3) compared to the Mini (Allwinner A20). This means they also use different Linux kernels so the kernel modules for the Mini are not compatible with the Maxi. They would need to be recompiled specifically with the SDK/kernel source and kernel configuration of the Maxi, but we do not have that SDK/kernel source nor kernel configuration. I've had some hit and miss results compiling modules using an Allwinner SDK for the Orange Pi or Nano Pi, some modules work but some (notably USB2Ethernet adapter support) just crash. I'll try to compile the x360 modules and see if they work. Any luck with compiling? I have tried to locate compiled drivers in any binary distribution but so far no hit. Will next try to disassemble Retrorangepi build for the H3, maybe I can find them there.
|
|
|
Post by jj0 on Nov 16, 2020 10:48:02 GMT
The issue is that the Maxi uses a different SoC/CPU (Allwinner H3) compared to the Mini (Allwinner A20). This means they also use different Linux kernels so the kernel modules for the Mini are not compatible with the Maxi. They would need to be recompiled specifically with the SDK/kernel source and kernel configuration of the Maxi, but we do not have that SDK/kernel source nor kernel configuration. I've had some hit and miss results compiling modules using an Allwinner SDK for the Orange Pi or Nano Pi, some modules work but some (notably USB2Ethernet adapter support) just crash. I'll try to compile the x360 modules and see if they work. Any luck with compiling? I have tried to locate compiled drivers in any binary distribution but so far no hit. Will next try to disassemble Retrorangepi build for the H3, maybe I can find them there. I've compiled the drivers but there are still some symbols missing so still trying to figure it out.
|
|
|
Post by spannernick on Nov 16, 2020 14:28:00 GMT
Oh just seen the other post by jj0, ok thats is a start-up script, I can do it so PCUAE copies all the files over to the firmware for you so you will not need to do anything at all, and it will only do it once then reboot. It will be in a folder in Options called `XPAD_ XBox_360_Contoller_for_Mini` and it will check if its running on the Mini if its running on a maxi it will not copy the XPad files over so it will only work on THEC64 Mini, and when THEC64 Maxi version comes out I will do the same.. wow, never ever saw me making scripts like this months ago.. if it was not for jj0, I would know nothing, Thanks man
|
|
|
Post by jj0 on Nov 16, 2020 14:59:42 GMT
Oh just seen the other post by jj0, ok thats is a start-up script, I can do it so PCUAE copies all the files over to the firmware for you so you will not need to do anything at all, and it will only do it once then reboot. It will be in a folder in Options called `XPAD_ XBox_360_Contoller_for_Mini` and it will check if its running on the Mini if its running on a maxi it will not copy the XPad files over so it will only work on THEC64 Mini, and when THEC64 Maxi version comes out I will do the same.. wow, never ever saw me making scripts like this months ago.. if it was not for jj0, I would know nothing, Thanks man I'm flattered, thanks. For the record, I think you;re doing a great job in creating and maintaining PCU and incorporating new things into it, it is surely the most popular tool for TheC64 hacking. Btw, you don't need to copy the files over to the Mini, you can just run the script from a PCU directory if you edit the directory path for the insmod statements to point to that directory. That way the Mini stays uncontaminated.
|
|