Close
0%
0%

MIDI Drum Module (MkII)

A Roland-compatible drum module. Built using mostly off-the-shelf parts.

Public Chat
Similar projects worth following
Recently I was able to get my hands on a handful of Roland drum pads however the drum module is shot.
The plan is to use an Arduino setup to read a group of each pad and send data to a pc as MIDI data.
In the future a raspberry Pi will be added to give some on-board sound output.

A Roland Dual-trigger drum pad outputs two signals via a TRS jack.

The main pad sensor is on Tip, rim sensor on Ring and both are grounded to  Sleeve.

Reading both sensors requires two Analog pins. Most arduino boards have 8 analog pins, meaning i would be able to have 4 pads wired up. This would be good enough for adding a few drumpads to an acoustic kit, for example.

The Arduino Mega has 16 analog pins - ideal for a bigger setup.

Project Outline

I aim to use an Arduino Mega to read 8 pads and send data to an Arduino Pro Micro

The Pro Micro can act as a USB MIDI device without having to flash anything to it, so it will be perfect for taking the Mega data and sending it as a MIDI command to an attached PC running some drum software.

I am going to explore using SPI to pass data between the two boards. I am thinking about using the Pro Micro as the SPI Master, potentially opening the door to adding extra Megas as slaves to add more pads, or even using a bank of Nanos in place of the Megas.

***August 2020 update***

Another avenue I am going to explore is using some 4051 Expander chips to take the pro micro and add enough pins to not require a slave Arduino. This would cut down on any latency introduced by having an extra layer of communication.

Also, having experimented with Pure Data recently for another project I am going to be using it on a Pi to receive data from the microcontroller and trigger sounds based upon it.

While MIDI will be still the planned communication method I also haven't ruled out using standard serial or OSC. I may even add an option to send all three, and use a switch to select the mode.

  • Building a test unit

    Craig Hissett08/13/2020 at 23:26 0 comments

    Now I have a bit more of a clear game plan it's time to assemble a box to test with.

    I had an old black enclosure I'd bought for my Pi powered Guitar effects pedal that didn't end up getting used, so I've drilled in some holes for jack sockets and a hole for a power cable.

    There are 4 jacks; 3 x stereo pad inputs and 1 x stereo output.

    Inside the case I've added an Arduino Micro, mini breadboard and a breadboard power supply.

    The input jacks will be having some wires soldered to them and attached to the arduino's analog pins and 5v rail via the breadboard; using a breadboard in this instance allows for the inputs to be free configured for different input devices easily.

    The output jack will have a 3.5mm audio cable chopped and soldered onto it and plugged into a Pi 3, which will be mounted in the case very soon; quality doesn't need to be great for testing, but I have a justBoom amp/DAC HAT which would vastly improve the quality of the ouptut.

    For the software I'm going to load Patchbox OS onto the Pi, as it is preconfigured for low latency audo performance, and can run Pure Data well.

    Coding for the Arduino will be fairly simple; loop through analog pins and check the value. If it is >0 and greater than the previously checked value then a hit has been detected, so send a corresponding serial message for the pure data patch to then route and play the correct sample.

  • Project back on!

    Craig Hissett08/12/2020 at 19:47 0 comments

    My SamplePad controller MkI worked well, but there's room for improvement. I'm now considering this project my mains project, and will be documenting my experiments with Pure Data, Arduino and the 4051 analog expander chips for adding more analog pins and reducing the number of Arduinos needed.

    Booyah!

  • Project still in development

    Craig Hissett08/23/2019 at 00:22 0 comments

    Just a quick update on this project of mine :)

    I haven't forgotten about this project, however a lot of the development for the software of this one is intertwined with my #DIY SamplePad Controller project as well; both will use the same code to read the pads and then just process them differently. This project's Arduino Mega uses a single serial port to pass data to the Pro Mini for turning into MIDI output, and the SamplePad's Mega uses four software serial ports for sending commands to four DFplayer mini boards.

    There's a strong chance Id like to leave an option for MIDI output on the SamplePad in the future, so it makes sense to develop the Megas code for both projects as one, with options to turn features on/off in the sketch.

  • I2c Testing

    Craig Hissett03/21/2019 at 00:50 0 comments

    Just a little update tonight, testing out my i2c premise.

    The Mega successfully passes data to the Pro Micro, which is great news.

    Now I just need to tighten it up and make sure it's fast and robust, then tidy up the Mega's pad reading code.

    Then it'll be time to stick a load of Jack sockets in a box with lots of Arduinos ha ha!

  • Draft Code | i2c

    Craig Hissett03/19/2019 at 00:32 0 comments

    First draft of code written, ready to test tomorrow:

    I have taken some working test code I had written for the Pro Micro and splits out its functions; the pro micro now becomes an i2c master, converting receive data into MIDI commands, and the slave device will focus on reading pads and sending values back to the master. In this example I'll be putting the slave code onto a Mega, giving 16 analog inputs (enough for 8 pads).

    If this works I'll be a happy man, as it'll allow me to easily add more slaves to give me the number of analog inputs needed, or allow me to use clusters of smaller boards, such as Nanos.

View all 5 project logs

Enjoy this project?

Share

Discussions

Koaps wrote 07/19/2020 at 17:23 point

really cool project, I want to do something like this also but I was thinking of using a Sparkfun Tsunami Super WAV Trigger I brought a while ago, should make it easy to trigger sounds really fast.

  Are you sure? yes | no

Craig Hissett wrote 08/12/2020 at 19:45 point

I like your thinking!

I've been doing some more work along these lines for another project of mine not documented here, and have got some good ideas coming for this involving Pure Data. Keep an eye out for updates!

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates