Close
0%
0%

DIY SamplePad Controller

A unit to allow sample audio files be triggered and played by Roland drum pads

Public Chat
Similar projects worth following
While working on my MIDI Drum Module project I was asked to explore making a smaller standalone module to allow the use of a small number of pads to augment an acoustic drum kit.

The drummer in question currently uses an Alesis Samplepad alongside his kit; it offers 4 pads, and an SD Card slot to load sounds onto the device. It has a small screen for displaying sample information, and a few buttons/knobs for sample adjustment.

What I propose to assemble will allow for 3xdouble trigger pads to be used to trigger onboard samples, much in the same way as the Alesis device.

The requirements I need to meet are as follows:

  • The controller must support a minimum of two Roland pads
  • The controller must be able to replicate the soundset of the Alesis Samplepad it will be replacing
  • It must be easy to add new sounds
  • It must be simple to use
  • It must be robust

Hardware

I have researched a few options in order to help establish the best way to achieve the requirements.

My initial instinct was to build a Pi-based solution and use an analog Zero pHat I have to attach the pad inputs, using python to read the pads and play audio files, however I feel that the need to safely shut it down wouldn't meet the simplicity or robust requirements in my eyes.

After some further searching for a Microcontroller-based answer to the problem I stumbled across the DFRduino M0 board by DFRobot. The board looks perfect; An ARM Cortex M0 board, complete with an IIS chip onboard for handling audio processing. The board is less than $10 too!

After looking further into this board I found the perfect companion shield for the board: Audio Shield For DFRduino M0. Complete with Micro SD card slot, line out and recording features and a small onboard amp, this board will give me the functionality I need to achieve all of the above targets and give plenty of features for future development.

In addition to this shield I will also include an i2c 16x2 LCD screen and a rotary encoder for menu and navigation control. Add in a handful of 1/4" jack sockets and an enclosure and this should give us a complete unit.

Software

I have a rough idea on how I am going to tackle the code of this project:

Sample sounds will be uploaded to the MicroSD Card, and follow a naming convention of group number followed by the intended pad to trigger it. For example, 1_1m.wav will be the sound for pad 1 main in group 1, and 3_3r.wav would be the sound for pad 3 rim in group 3.

The rotary encoder and lcd will allow the setting of the volume of the output and also the number of the group of sounds to be triggered - switching between the two will be done by pressing the encoder button.

The main loop of the code will check the pad pins (A0-A5) and check for a reading; if > 0 then a hit has been registered. The play command will send the name of the pad, the currently selected group number and the reading of the analog pin.

The Reading will be mapped against 100 and used to dictate the percentage of the main volume that the sound should be played, allowing velocity of the hit to be reflected in playback. The group number  and pad name will be combined to give the name of the file that should be triggered from the SD card.

  • 1 × Enclosure - TBC Big enough to hold your boards and allow for drilling of holes for jacks, screen, encoder and power
  • 1 × DFRduino M0 Mainboard (Arduino Compatible) https://www.dfrobot.com/product-1654.html
  • 1 × Audio Shield For DFRduino M0 https://www.dfrobot.com/product-1656.html
  • 6 × TRS Jack sockets for connecting the pads (main, rim and ground connections)
  • 1 × Panelmount DC barrel socket to pass power to the M0

View all 9 components

  • Prototyping

    Craig Hissett7 days ago 0 comments

    While I wait for my DFRobot boards to arrive from China I'm going to work on the menu first.

    I have a few Arduino Nano boards kicking around; it's breadboard-friendly pin layout is perfect for prototyping. I also have an lcd display and a rotary encoder already, so I can attach those to the breadboard with some male-female jumper cables.

    This little setup will enable me to work on the menu and selecting/setting the parameters, and also committing the parameters to EEPROM so they can be loaded on startup.

    I have also ordered a little DFRobot mp3 module for this setup, which, when it arrives, will allow me to test reading data and playing sound from it's onboard Micro SD Card slot.

    Good times!

View project log

Enjoy this project?

Share

Discussions

Similar Projects

Does this project spark your interest?

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