MIDI Triggered Audio Player (to line out)

Hi Forum!

My goal is to build a small audio player for a guitar pedal board where a particular file on an SD card can be triggered when one or more MIDI message are received.

Ecosystem:

  • Morningstar MC-6 MkII midi controller
  • SingularSound BeatBuddy
  • SingularSound Aeros Loop Station
  • Fractal Audio FM-3

There are other items, but that’ll do for background!

So the MC-6 can send a midi message to devices in the MIDI chain to set up to for the song (patches etc), begin playing, pause playing, transition to song parts etc.

The BeatBuddy has an auxiliary in 3.5mm stereo jack that can mix with the BB generated audio and pass to a PA etc.

The device I build can be either USB or 9V DC powered from the pedalboard power supply (which puts out centre negative, but can be swapped).

From the research I have done so far, products like the SparkFun MP3 seem to be limited by the number of pins that are available to select a track. I envisage having lots of tracks (for example, up to 6 tracks per song, played in any given sequence depending on which part is selected on the BeatBuddy).

Major requirements…

  • 5pin 3.3V MIDI in and out(/through) - MIDI channel selectable. Worst case is that I could add a MIDI splitter box on the board to mirror its input to another cable on the chain and just have MIDI in on this device. I could also use some other form of box or device to take a 5pin MIDI cable and convert it to serial comms input on the arduino…i’d rather keep the number of additional devices to a minimum and I don’t want to have to have a computer or ipad etc to drive the rig…
  • Would be great if the playback speed of the audio file could be controlled also (for example, if the default tempo is 120bpm, and I chose to slow it down via the beat buddy, that could trigger a percentage change in the playback speed of the audio - that’s possibly getting a bit too adventurous!
  • SD-Card for audio files - media format not a big deal but number of files is a bigger deal (80+). card needs to be accessed from outside the enclosure
  • USB or 9VDC powered…
  • 3.5mm line out
  • Enclosed case - needs to be relatively rugged as it would stay on the pedal board

I’ve been looking at the “Adafruit Music Maker MP3 shield for Arduino” (ADA1790) to be paired with the Arduino Uno R3 (A000066), but nothing’s set in stone. I wasn’t keen to just buy stuff and find out that I can’t do something. I’m very new to the physical board stuff, but I’ve been a programmer for 40 years - C, C++, C#, Basic etc, but not had much to do with logic boards.

Any hints or references to previous projects would be greatly appreciated!
Craig

3 Likes

Hey Craig,

Welcome to the forum mate! That project sounds great!

Yes, most of the WAV and MP3 triggers can only store as many tracks as they have closable inputs which do get quite limiting if you need to store a large amount of music which you need to trigger based on various inputs (also, depending on the form of Audio Compression used in the filetype which will affect the memory requirements, particularly of longer tracks).

What sounds :sweat_smile: like the best solution as you’ve described is to use a BeatBuddy for your pedal, along with your MC-6 to send MIDI messages out appropriately. Some hardware that you may be able to use to throw this together would be a Teensy 3 or 4 (probably the 4) with some appropriate breakouts to be able to connect to MIDI and an Audio Adaptor board for storing all of the tracks you’re looking to trigger based on the messages. It’s quite a different project, but Ken’s Euclidean that he designed should have plenty of useful info for getting started and if you’re after tutorials for using the Teensy, we’ve got plenty of those available on the site completely free too (although I admit some are getting a little older now, definitely worth a read though, there should be a tutorial about using USB MIDI too if I remember correctly):

2 Likes

Thanks Bryce - that’s extremely useful. I have splashed out and purchased a selection of stuff and watched a couple of videos about how it all works and it seems to me that it should work well, perhaps apart from an enclosure. I’ll prototype it up and see how I go (when I eventually get delivery!).

Cheers

2 Likes

Hey Craig,

I’m wondering if @John136772 might be able to chime in on this one eventually, he does some awesome stuff with MIDI, audio, and teensies.

Cool project, keen to see it develop!
-James

In the mean time, check out his youtube:

Yes Teensy plus its audio shield is the most powerful combination for this sort of stuff. The teensy 4.1 has an SD card slot, and although I haven’t used it, it’s more than capable of holding sounds and playing them. The pjrc forum is very helpful and has a dedicated Audio project thread. Also, the best/easiest way to program it is using the Arduino IDE and the Teedsyduino add-on which is C based.

1 Like