May 12, 2008

Getting inside the WiiMote, I2C, PixArt and all that good stuff…

Filed under: Electronics — shobley @ 11:41 am
Getting inside the WiiMote, I2C, PixArt and all that good stuff...

Some of you will have noticed that I was able to modify a WiiMote to do visible light tracking recently. My goal was to produce a gesture tracking system for the laser harp.

This was OK, but having to use Bluetooth, and Windows was a PITA - I needed a hardware only solution that could be wired straight into the harp.

At the recent Maker Faire I talked to Johnny Lee about the amount of information available on WiiMote internals - he directed me to the WiiMote project forum and I was able to locate this post that hinted at how the PixArt sensor could be attached to a microcontroller using I2C.

http://www.wiimoteproject.com/other/red-laser-and-i2c-bus-done-t579.0.html

Post #34 is pretty crucial:

Here’s how I get this to work:
Remove Pixart sensor from wiimote.
The sensor needs a 25 MHz clock signal here’s a circuit and pinout:
http://www.kako.com/neta/2007-001/2007-001.html
Connect the Sensor to your MC (don’t forget the pullups)
The slave address is 0xB0.
Initialise like here
http://www.kako.com/neta/2006-019/wii_ir_test2_src.zip
http://www.kako.com/neta/2006-019/2006-019.html
Now send 0×38
Capture 8 Bytes from slave
Capture 4 Bytes from slave
(I’ve seen this by sniffing the Bus)
I’m not sure about how to interpret the data(Haven’t even tried this yet, maybe it’s like the basic report?)

Some tips:
Kako.com is Japanese I’ve used babelfish to translate to English http://babelfish.altavista.com/
You can connect the sensor to the extension port and use the wiimote as usual. (With 25MHz Clock extern)
If you have problems with desoldering the sensor you can carefully break the case of the sensor. There is a second SMD case around the cam. I’m not responsible on any damages!

Please share your experience with the community.
If somebody knows how to remove the IR filter please post it here!
Does somebody know if the sensor can be used with 5V?

Fortunately the good ‘ol Arduino has everything we need - 3.3v output and an I2C protocol, accessible using the Wiring language.

Here’s a nice article on using I2C with an Arduino

Over the next few weeks I’m going to be trying to create an Arduino/PixArt/WiiMote hybrid that is capable of 200Hz blob tracking and MIDI controller output…

Stay tuned!

But in the meantime - check out LadyAda’s excellent new Boarduino USB!
All the goodness of a regular Boarduino, now with the FTDI chip/USB built right in.

Using a blog responsibly…

Filed under: Photography — shobley @ 11:29 am

It’s funny, but when I first heard about “blogging” I couldn’t really grasp what all the fuss was about. The notion that you should post entries on the web that really should be kept in your private diary seemed rather strange.

I think that there is a major flaw in the whole blogging concept, (for most of us): When lots of stuff is happening in your life, you don’t have time to update your blog, then when things calm down a bit, there’s nothing to write…

Some people actually seem to make money doing this too - although I’m not sure how many people make liveable income from AdSense et al. I’ve always viewed it as something that produces “bonus” money, but no steady stream of income.

So anyway, I thought it was about time that I used my blog a bit more responsibly and actually posted things that might be of use to the rest of the human race…

More pictures from the Maker Faire

Filed under: MIDI and Music — shobley @ 9:38 am
More pictures from the Maker Faire

Skip Russell emailed me to send me this link to his pictures from the Maker Faire - great job, as the lasers are not easy to capture on camera…

http://www.flickr.com/photos/skipr/tags/laserharp/

Looking at the EXIF data, it was 18mm, at 1/5s F3.5 - not sure about the ISO, but I should imagine it was set fairly high. Short exposure time and center-weighted metering help to capture the swirling fog patterns quite nicely…