DIY: Angry Birds USB Slingshot


From mbed:
To make Angry Birds a real sport, we need real equipment. So the idea for this hack was to build a real slingshot as a USB peripheral to play Angry Birds. It was inspired as a demo to show off how easy it is becoming to build your own USB devices, thanks to the emergence of ultra-low-cost 32-bit microcontrollers that include USB.
The slingshot emulates a USB mouse, so it really is a plug 'n' play. It translates the physical use of the slingshot in to appropriate mouse controls.
With a real slingshot, you tilt the slingshot and stretch sling. The idea to measure these was using:
  • An accelerometer - this can measure the tilt by tracking the gravity vector (which way is down!)
  • A rubber stretch sensor - this can be used as the sling, and measure how much it is stretched
That is the input, but to play Angry Birds, you actually click on the bird, then drag to the launch angle and strength you want, then release. This means we have to translate the real slingshot movements in to a series of different mouse movements.
For example, this means translating starting to stretch the slingshot to a mouse to click and hold, whilst the vector of the stretch determined by the angle of sling and how far it is stretched translates to mouse movements relative to where we started...
Want to see a demo?


(read the instructions @ mbed)
Next Post Previous Post