On the hardware side I threw together a harness out of ShapeLock and mounted eight pinball microswitches. The wiimote would slide into place and the arduino could be bolted on. A pretty ugly monstrosity to be sure, but it more-or-less worked. I got bored with the project before getting around to writing a keymap.
Thursday, January 3, 2008
Update
Well, obviously I've lost my enthusiasm for keeping this site and blog updated. I did get the arduino working and made a post on the arduino forum about it. Chad over at windmeadow.com has done something similar; see this post for arduino-as-peripheral and this one for arduino-as-nunchuk-master.
Wednesday, February 21, 2007
Success!
I've succesfully sniffed the perihperal bus. I've updated the firmware page with a link to the details of my sniffing adventure. The short version is that the peripheral bus is Fast-I2C compatible, with a 400kHz clock, a master (presumably the wiimote), and a slave at address 0x52 (presumably the nunchuck).
Thursday, February 15, 2007
Hardware update
After much consternation, running of lmilk, and reflashing of my arduino board, I am still unable to get anything that looks like valid I2C traffic from the peripheral bus. It's just possible that my arduino board is still too slow, as with an extra timing loop I clock in at around 200Khz, but it ought to be fast enough when I take the timing loop out. It's also possible that lmilk doesn't work at these frequencies (at least not with the ~6ft parallel cable I'm using). But at this point I am starting to suspect that this page might be fake. I just put in a sample order for some pca9539 chips, so when they arrive I'll try to duplicate his circuit exactly and see what happens.
Tuesday, February 13, 2007
Waveforms
Here's some of the output from my arduino sniffer. The height of the character traces the clock line (big for high, small for low) and the shape traces the data line (1/i for high, 0/o for low).
Each of these is surrounded by a great number of 1's. Each ought to correspond to roughly the same transaction; a querying of the nunchuk for about 6 bytes of (mostly) identical data. Unfortunately I don't know the precise sample rate. For reference, here's what I would expect on an I2C bus, if we were sampling at four times the clock speed. In this example the Master requests data from slave with address 0b0000001, and it responds with one byte of data, 0b1001011. (This is assuming I've correctly understood I2C, perhaps it's a bit off.)
...11111111io0oooooooo0ooo11111i0oo0oiiiiiiiiiiiiii1iioi1iii1ii1ii0iiii1ii1ii00ii1ii01111111...
...11111ooo0iiiiiiioii0iiiiio1iiiiioi0ooioii1ioiiiiioi1ooiiiiiioo1iiiiiii0iiiiiiiiii1io111111...
...11100oooo0oo0oooo111101ioii0iiiiiiiiiiiiiii1io1ii11oi1i1ii1ii1oii1ii1i1ii1i01111111110i1oiioiiiioi1oooiiiiiii1oiio1oo0iiiiioiiiiioii0ooiiiiii0ioiiiiiiiii1ioiiii1iioooo011...
Each of these is surrounded by a great number of 1's. Each ought to correspond to roughly the same transaction; a querying of the nunchuk for about 6 bytes of (mostly) identical data. Unfortunately I don't know the precise sample rate. For reference, here's what I would expect on an I2C bus, if we were sampling at four times the clock speed. In this example the Master requests data from slave with address 0b0000001, and it responds with one byte of data, 0b1001011. (This is assuming I've correctly understood I2C, perhaps it's a bit off.)
11110000oooo0000oooo0000oooo0000oooo0000oooo0000oooo0000ooii1111iioo0000ooii1111iiii1111iioo0000oooo0000ooii1111iioo0000ooii1111ii1111ii1111iioo00001111
START ----------------------Device 1 --------------------- READ -- ACK ------------------------------- 0b10010111 -------------- STOP
Monday, February 12, 2007
Hardware progress
Using my handy triwing screwdriver I opened the Nunchuk attachment. Consulting the pinout from wiire.org, I soldered wires onto the Clock and Data lines. I attached my oscilloscope and confirmed a 250kHz clock rate, but my 'scope wasn't sophisticated enough for me to read the bits manually. I bought an Arduino from SparkFun; I was hoping to use the Wire library to sniff the may-or-may-not-be-I2C bus. I have seen some signs of life, but no actual data yet. I'll also try this simple approach using only the parallel port on my PC, but it does specify 100kHz on that page, so it may not work.
Thursday, February 8, 2007
Stubbing out the site
I've filled out the front page with links to the five subpages:
Electronics, Hardware, Peripheral Firmware, Host drivers, and Updating the Wiimote Firmware. Right now these just contain basic sketches of how I plan to proceed.
Electronics, Hardware, Peripheral Firmware, Host drivers, and Updating the Wiimote Firmware. Right now these just contain basic sketches of how I plan to proceed.
Welcome
First post!
For a while now, I've had an idea bouncing around my head and taking various forms. But only yesterday did it finally coalesce into a single mission: to build a bluetooth-enabled, battery-powered hand-held chording keyboard out of a Wii Remote.
Since I'm a google fanboy (and, coincidentally, employee) I'll be test-driving a bunch of google tools for this project. I just registered twiidler.org using Google Apps for your Domain for ten bucks. It went through very quickly and I was soon using Google Page Creator to sketch out the front page.
Stay tuned to this blog for further updates.
For a while now, I've had an idea bouncing around my head and taking various forms. But only yesterday did it finally coalesce into a single mission: to build a bluetooth-enabled, battery-powered hand-held chording keyboard out of a Wii Remote.
Since I'm a google fanboy (and, coincidentally, employee) I'll be test-driving a bunch of google tools for this project. I just registered twiidler.org using Google Apps for your Domain for ten bucks. It went through very quickly and I was soon using Google Page Creator to sketch out the front page.
Stay tuned to this blog for further updates.
Subscribe to:
Posts (Atom)