Dolphin, the GameCube and Wii emulator - Forums

Full Version: Make 3rd party Wiimotes work (in-game) (Linux/Mac OS X)
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Hi!

I managed to make my 3rd party Wiimote work with Dolphin in-game.

The symptom was that that my 3rd party Wiimote ( http://cgi.ebay.ie/ws/eBayISAPI.dll?View...0393544125 ) was able to sync with Dolphin, but only games that use the main buttons of the wiimote worked (there aren't many of those, I suppose). Anything that uses motion sensing or the nunchuk wouldn't

After some head/wall encounters, I realized that the remote wasn't even replying to the first packet a game is sending it. E.g., in Mario Kart, I see "a2 17 00 00 17 70 00 01".

Turns out that this Wiimote (and probably most other 3rd parties, I wouldn't be surprised if all used the same chipset) doesn't understand DATA packets (the `a' in a2). No reply ever comes out.

That "a2 17 00 00 17 70 00 01" is actually an eeprom read request. If you look at
http://wiibrew.org/wiki/Wiimote , you'll see that a2 packets aren't even documented. It documents using 52 (5 == set report) instead. By making the real wiimote code swap those a2's for 52's, the 3rd party Wiimote starts working perfectly. I also tested with a real Nintendo Wiimote (one of those with a builtin motionplus), and I can confirm that it still works after the change.

52 is also what libcwiid sends, and that's the reason that wmgui works out of the box with this wiimote.

I can only imagine that since this Wiimote supposedly works work the real Wii, that if we sniffed the bluetooth traffic between the Wii and this Wiimote, we'd indeed see 52's instead of a2's.

I'm attaching the minimal fix I came up with.

BTW, I'm on Linux (x86_64-linux ubuntu 11.04).

Sonic1 pointed me that the old wiiuse code also used to do this translation.

http://www.google.com/codesearch#fwGbquB....com&l=325
(10-02-2011, 04:08 AM)pholklore Wrote: [ -> ]Hi!

I managed to make my 3rd party Wiimote work with Dolphin in-game.

The symptom was that that my 3rd party Wiimote ( http://cgi.ebay.ie/ws/eBayISAPI.dll?View...0393544125 ) was able to sync with Dolphin, but only games that use the main buttons of the wiimote worked (there aren't many of those, I suppose). Anything that uses motion sensing or the nunchuk wouldn't

After some head/wall encounters, I realized that the remote wasn't even replying to the first packet a game is sending it. E.g., in Mario Kart, I see "a2 17 00 00 17 70 00 01".

Turns out that this Wiimote (and probably most other 3rd parties, I wouldn't be surprised if all used the same chipset) doesn't understand DATA packets (the `a' in a2). No reply ever comes out.

That "a2 17 00 00 17 70 00 01" is actually an eeprom read request. If you look at
http://wiibrew.org/wiki/Wiimote , you'll see that a2 packets aren't even documented. It documents using 52 (5 == set report) instead. By making the real wiimote code swap those a2's for 52's, the 3rd party Wiimote starts working perfectly. I also tested with a real Nintendo Wiimote (one of those with a builtin motionplus), and I can confirm that it still works after the change.

52 is also what libcwiid sends, and that's the reason that wmgui works out of the box with this wiimote.

I can only imagine that since this Wiimote supposedly works work the real Wii, that if we sniffed the bluetooth traffic between the Wii and this Wiimote, we'd indeed see 52's instead of a2's.

I'm attaching the minimal fix I came up with.

BTW, I'm on Linux (x86_64-linux ubuntu 11.04).

Sonic1 pointed me that the old wiiuse code also used to do this translation.

http://www.google.com/codesearch#fwGbquB....com&l=325

Where do you place this file? What folder??

Learn this first, then we will tell you. Or request a patched build from a compiler (maybe Xtreme2Damax, or ExtremeDude2, but don't quote me on that).
http://code.google.com/p/dolphin-emu/wiki/Windows_Build
please try this build of dolphin if you are having trouble connecting non-nintendo wiimotes (on windows): https://min.us/lVwefgFOiXF8d
[Sorry, I've been (still am) away]

The patch in this thread DOES NOT HELP WINDOWS USERS. Only Linux and Mac OS X.
that's why my build does Smile
Yeah, I wasn't talking at you, but at the users that wanted to know how to use The Patch. :-)

I guess it's useful to point Windows users at issue 4833.

http://code.google.com/p/dolphin-emu/iss...il?id=4833
how to apply this patch, put in the folder and make??
can't find file to patch at input line 9
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|---
| Source/Core/Core/Src/HW/WiimoteReal/WiimoteReal.cpp | 10 +++++++++-
| 1 file changed, 9 insertions(+), 1 deletion(-)
|
|Index: src/Source/Core/Core/Src/HW/WiimoteReal/WiimoteReal.cpp
|===================================================================
|--- src.orig/Source/Core/Core/Src/HW/WiimoteReal/WiimoteReal.cpp 2011-10-01 18:26:53.670122058 +0100
|+++ src/Source/Core/Core/Src/HW/WiimoteReal/WiimoteReal.cpp 2011-10-01 18:59:12.790123404 +0100
--------------------------
File to patch


Any ideas??

Finally done.
just use:
$ patch p1 < (patch that you downloaded here)

Unfortunally , did'nt work for me...
Just use latest dolphin Wink
Thx dude, I'll try to compile it again... Will post results tomorrow...
Pages: 1 2