Step 6: Code

Step 7:

Here's a quick video of my drums in action:

This instructable will tell you how to make your own set of air drums using little more than an Arduino microcontroller and a few accelerometers.
Here's a video of the drums I based this design off of:

My drums feature a number of improvements over those shown in the video:

-Funtional Hi Hat Pedal: Looking at the original designer's code, I noticed he never got the photocell "hi-hat" to work. Instead, he programmed the cymbal drumstick to play a crash at high acceleration and a closed hi hat at lower accelerations.

Step 2: MIDI Connector

The first thing you'll want to do is wire up your Arduino to your MIDI female connector so you can play MIDI notes. This is an easy process - just follow the diagram! Note that the resistor is 220 ohm.

Step 3: Wiring up the Accelerometers

Next, we want to hook up our accelerometers to the Arduino. Hook up the z terminals of the accelerometers to the analog inputs 0,1, and 4 of the arduino. Hook up the GND terminals to ground and the VCC terminals to the +3.3V of the Arduino. Also, hook up the Analog Reference pin to +3.3V. For reference, see the diagram below.

Also, to avoid long, tangled wires, use usb cables as connectors. Just solder the wires from the accelerometer onto the usb females and use usb males to connect them. The picture below shows a USB female with accelerometer cables soldered to it.

Hello, i try to do the same thing and i will thank you for your post... BUT.... There is for me 2 mistakes

1- in your comment you say "Hook up the z terminals of the accelerometers to the analog inputs 0,1, and 4 of the arduino." for me it's wrong and doesn't work... i have to put A0 (hithat) A2 (snare) A3 (Crash) A4 (Bass), and this work much better

2- My Hit Hat doesn't work... :'( When we look to your program they is a line with "int CrashPin = A5;" You never said to put something in A5 analog pin.... And When we look CLOSER to the picture to your system (Step 5, where there are the 4 usb) we can see that : Top to bottum 1st usb -> 2 wire -> hithat Photocell OK 2nd usb -> 3 wire -> Snare or Bass OK 3rd usb -> 3 wire -> Bass or Snare OK 4th usb -> 4 wire -> accelerometer HITHAT ? Why? in your schema you never put 4 wire. (step 3) I think, i need a wire on the A5 pin .... ?

i put a LED on the photocell this is working, my crash is OK Bass OK , Snare OK