Introduction: Arduino Wheel Chair Drum Kit
Sam has wanted to play music ever since he was was young but his Cerebral Palsy limits his ability to play most standard musical instruments. A couple of moths ago he decided that he would like to play the drums, and so we went to work to find a solution.
This electronic drum machine is triggered by buttons on the head support of his wheel chair. He is now able to join the Church worship team and help support the congregation in their singing and praise. Go Sam!
Step 1: Parts
Arduino uno
1 X 220K Resistor
3 X 10K Resistors
3 X Jelly Bean Twist Switches
3 x 3.5mm Mono Jacks - female
1 X 5 Pin DIN PANEL Socket (MIDI)
1 x Jiffy box
1 x 5 pin MIDI Cable
1 X MIDI generator (Key board, electronic drum controller, PC - I used an electronic drum kit controller)
Amp (we plug directly into our PA)
Step 2: Arduino MIDI Note Generator
Connect the components as per the wiring diagram and mount them in the jiffy box
Step 3: Software
Add the Arduino_MIDI_Library_v4.2 and Bounce2-master librarys to your Arduino programming application.
https://github.com/FortySevenEffects/arduino_midi_...
https://github.com/thomasfredericks/Bounce2
Copy and paste the following into an arduino sketch and down load it to your arduino.
You may have to play around with the MIDI note numbers depending on the device you use to process them.
#include
#include
MIDI_CREATE_DEFAULT_INSTANCE();
const int button_1 = 2;
const int button_2 = 3;
const int button_3 = 4;
const int button_4 = 5;
const int button_5 = 6;
const int button_6 = 7 ;
Bounce debouncer1 = Bounce();
Bounce debouncer2 = Bounce();
Bounce debouncer3 = Bounce();
Bounce debouncer4 = Bounce();
Bounce debouncer5 = Bounce();
Bounce debouncer6 = Bounce();
void setup() {
MIDI.begin(MIDI_CHANNEL_OMNI);
pinMode(button_1 , INPUT_PULLUP);
pinMode(button_2 , INPUT_PULLUP);
pinMode(button_3 , INPUT_PULLUP);
pinMode(button_4 , INPUT_PULLUP);
pinMode(button_5 , INPUT_PULLUP);
pinMode(button_6 , INPUT_PULLUP);
debouncer1.attach(button_1);
debouncer1.interval(5);
debouncer2.attach(button_2);
debouncer2.interval(5);
debouncer3.attach(button_3);
debouncer3.interval(5);
debouncer4.attach(button_4);
debouncer4.interval(5);
debouncer5.attach(button_5);
debouncer5.interval(5);
debouncer6.attach(button_6);
debouncer6.interval(5);
}
void loop() {
debouncer1.update();
debouncer2.update();
debouncer3.update();
debouncer4.update();
debouncer5.update();
debouncer6.update();
if ( debouncer1.rose () ) {
MIDI.sendNoteOn(38, 120, 1);
delay(10);
MIDI.sendNoteOff(38,0,1);
}
if ( debouncer2.rose () ) {
MIDI.sendNoteOn(36, 120, 1);
delay(10);
MIDI.sendNoteOff(36,0,1);
}
if ( debouncer3.rose () ) {
MIDI.sendNoteOn(48, 120, 1);
delay(10);
MIDI.sendNoteOff(48,0,1);
}
if ( debouncer4.rose () ) {
MIDI.sendNoteOn(45, 120, 1);
delay(10);
MIDI.sendNoteOff(45,0,1);
}
if ( debouncer5.rose () ) {
MIDI.sendNoteOn(43, 120, 1);
delay(10);
MIDI.sendNoteOff(43,0,1);
}
if ( debouncer6.rose () ) {
MIDI.sendNoteOn(49, 120, 1);
delay(10);
MIDI.sendNoteOff(49,0,1);
}
}