Page 1 of 3

Use a Wii Motion Plus, using I2C interface ?

Posted: 02 Feb 2011, 17:34
by dt22
Hello everybody,

I’ve read that the wii motion plus was a i2c sensor and I found pretty cool to interface this sensor with the Mindstorms Brick. There plenty of documentation on the web about the protocol or how to interface this with an arduino for exemple but no documentation on how interface this sensor with the NXT brick.

As the consequence I ask the question if it is possible? Moreover do you think necessary to change the resistances on I2C wire in the same way as it is necessary to change these resistance in order to connect the nunchuk ?

Re: Use a Wii Motion Plus, using I2C interface ?

Posted: 02 Feb 2011, 19:18
by mattallen37
I do believe that it IS an I2C sensor as well. To interface it, it would probably be almost identical to the nunchuck, including needing to replace the pullups. You will need to program the NXT on the level you would need to use to use the nunchuck, meaning that you would need to understand how to do custom I2C communication. I would suggest NXC (almost any language other than NXT-G would probably be best).

Yes, it should be very possible, and yes you should change the pullups.

BTW, what sensors does the "Wii Motion" have? Is it gyros? I know that the WiiMote already has an accelerometer, so i'm sure that is not what the Wii Motion has.

Re: Use a Wii Motion Plus, using I2C interface ?

Posted: 02 Feb 2011, 19:28
by dt22
mattallen37 wrote:You will need to program the NXT on the level you would need to use to use the nunchuck, meaning that you would need to understand how to do custom I2C communication. I would suggest NXC (almost any language other than NXT-G would probably be best).
This part must not be a problem, i program with NXC and I have already modify some i2c api sensors. My fear is if there an incompatibility due to baudrate or something else. And i'm surprise do found nodody on google who made this or ask the question.
mattallen37 wrote:BTW, what sensors does the "Wii Motion" have? Is it gyros? I know that the WiiMote already has an accelerometer, so i'm sure that is not what the Wii Motion has.
The wii motion is a 3-axis gyro

Re: Use a Wii Motion Plus, using I2C interface ?

Posted: 02 Feb 2011, 21:16
by mattallen37
dt22 wrote:This part must not be a problem, i program with NXC and I have already modify some i2c api sensors. My fear is if there an incompatibility due to baudrate or something else. And i'm surprise do found nodody on google who made this or ask the question.

The wii motion is a 3-axis gyro
Ok, I just wanted to let you know that you can't expect any official drivers for the device. Most I2C slaves can tolerate any sluggish speeds. The nunchuck works fine (or so I've heard), so the Wii Motion should be okay on the incredibly slow NXT I2C bus.

Wow, that is really cool. I should look into getting one or two. It's hard to believe how cheap the Wii stuff it, compared to what other accelerometers and gyros cost.

Re: Use a Wii Motion Plus, using I2C interface ?

Posted: 02 Feb 2011, 23:25
by nxtreme
dt22 wrote:The wii motion is a 3-axis gyro
Yes, more info at WiiBrew.

Re: Use a Wii Motion Plus, using I2C interface ?

Posted: 03 Feb 2011, 00:17
by mattallen37
nxtreme wrote:Yes, more info at WiiBrew.
Wow, lots of good info there. Thanks for the link, I will definitely save it.

Re: Use a Wii Motion Plus, using I2C interface ?

Posted: 03 Feb 2011, 11:18
by hergipotter
Funny, i had the exact same idea yesterday :D

I've got an Motion Plus here and will do some testing this weekend...
Please keep us updated on your progress, dt22!

Re: Use a Wii Motion Plus, using I2C interface ?

Posted: 03 Feb 2011, 12:11
by dt22
hergipotter wrote:I've got an Motion Plus here and will do some testing this weekend...
Please keep us updated on your progress, dt22!
At this moment i've no wii motion here. I will buy one soon with the resistences and diode.

Re: Use a Wii Motion Plus, using I2C interface ?

Posted: 03 Feb 2011, 13:17
by hergipotter
Found some interesting links, i think they may help us.

http://123a321.wordpress.com/2009/08/21 ... s-via-i2c/
http://randomhacksofboredom.blogspot.co ... -love.html

But what resistors are the pull-ups? R1 and R2 just like with the nunchuk?

Re: Use a Wii Motion Plus, using I2C interface ?

Posted: 03 Feb 2011, 21:05
by mattallen37
hergipotter wrote:...But what resistors are the pull-ups? R1 and R2 just like with the nunchuk?
Just follow the traces on the PCB.