Nintendo Wii controlled Cannon??

Don't want to see this ad? Sign up for anRPF Premium Membershiptoday. Support the community. Stop the ads.

Giles

New Member
Hi all,

I've tried searching under a number of different words in 'The Arsenal' and couldn't come across anything so...... a while back I saw on the Gadget Show (UK hunters) the presenters controlling a Robotwars style machine with two nintendo Wii controllers which has popped into my head whilst having lunch and got me thinking. If you can use a Wii remote to control a radio controlled vehicle (See attached youtube link at the bottom), could you use the accelerometers to control the cannon?

I know there are a few people on youtube have designed some cannons which use a wireless remote, or one that is wired up but I think this might be a cool method to have the cannon actually linked to the head movement giving it a much wider range of movement.

Just throwing this out there to see if anyone has investigated the possiblity, and discovered it will/does/doesn't work, before I dive head long into the a world of motion tracking, electronics and computer programs that I know nothing about (and to give myself something different to work on when I get frustrated with my sculpt!!)

http://www.youtube.com/watch?v=Qlukl5fLi7s

Cheers

Giles
 

Don't want to see this ad? Sign up for anRPF Premium Membershiptoday. Support the community. Stop the ads.

pill baxton

New Member
I would be interested in seeing this get made, Im definetly gonna be following this thread. Just one more reason Im in love with my Wii :rolleyes:
 

Honus1

New Member
The Wii nunchuck board is very easy to interface to a microcontroller over its I2C bus. I wrote my original controller code over three years ago and it works like a charm. The trick is getting all the movements of the cannon just right and getting the sound to sync up so there is a bit of work there to get it all dialed in. A P1 cannon mechanism is a complex little beast- my setup uses three microcontrollers (two for the three servos and one for the sound effects.)

Using the Wii nunchuck board doesn't give you true head tracking but it's good enough once you learn how to use it and it's relatively inexpensive. True head tracking would be pretty expensive and tricky to implement. Probably the least expensive method would be to use a digital compass (magnetometer) with tilt compensation but a board like that alone costs about $150. Contrary to popular belief a compass or gyroscope alone won't work. The problem with gyros is that you need two of them, preferably with an accelerometer to account for drift as well as front/rear tilt (pitch). One gyro really won't work well because it will respond to whole body rotation as well as just head rotation, so you would need one IMU (inertial measurement unit) at the head and another at the cannon base and then you have to write some code to differentiate between the two. Gyros really only sense change in angular velocity so its output only changes with respect to movement and it will reset itself once you stop rotating your body- the cannon will quickly become out of sync with your movements. That's why to really do it right you need a multiple DOF IMU and you need two of them (along with some complex code/algorithm) for true head tracking. Most of the systems I've seen that people post online as a head tracking system for R/C or video control have very poor yaw control and this is why. And they don'tt even have to deal with the body rotation issue as they can sit in a chair- not an option for costuming.

There are IMUs available now that have on board processing and are programmed to account for drift so some of the hard work is done for you but you would still have to factor in the difference output of two of them and then generate your necessary servo movement values from that. It can be done but it's pretty darn expensive.

What I did was to basically fake it by strictly using the accelerometer inputs- when looking sideways you just need to tilt your head to the side like a bird for yaw (rotation) control. The accelerometer reads the tilt and moves everything accordingly- the pitch function is normal. The buttons control the arming and firing of the cannon.

For those people that would like to learn how to connect a $20 Wii nunchuck to a $20 arduino microcontroller I wrote up a little tutorial here for some of the Iron Man guys to use for their War Machine cannons: http://siwdat.com/forum/viewtopic.php?f=115&t=314

That tutorial could very easily be adapted for an AVP Pred cannon or a basic Pred cannon that only needs up/down and rotation (with or without sound effects) but it absolutely will not work for a P1 cannon- that's a whole different complex creature that people will see as soon as I get my hands on a P1 backpack from you know who. :)

Jerome
 

Don't want to see this ad? Sign up for anRPF Premium Membershiptoday. Support the community. Stop the ads.

woodstock8998

New Member
Hi man i have made a cannon of a wii remot nunchuck and mine works perfectly and been to comicons and shows and still works well .if need any info or help in happy to lend a hand
 

Don't want to see this ad? Sign up for anRPF Premium Membershiptoday. Support the community. Stop the ads.

Top