Let’s Talk Tsunami!


Tsunami is a new Robertsonics / SparkFun product, available now. Think WAV Trigger on steroids.

You can read the details on the new product page. I thought I’d use this post to discuss the design philosophy, how Tsunami differs from the WAV Trigger and what that means for you.

The WAV Trigger has been an ongoing exercise in optimization; trying to eke out the maximum performance in terms of number of voices without sacrificing quality and stability. I don’t ever want to hear a glitch, and nor should you!

While the WAV Trigger’s STM32F405 processor speed is certainly a factor, the limiting resource is actually the amount of on-board SRAM, used to buffer each wav file being played by a voice. The absolute maximum number of voices the WAV Trigger can support with 44.1kHz, 16-bit, stereo wav files is 14. Even then, I don’t have enough memory to support true seamless looping (which requires more buffering per voice.) With the latest WAV Trigger firmware release, I feel as though I’ve reached the performance limit for this platform.

Tsunami began when I read about the new Atmel S70 ARM Cortex-m7 processor and realized that it runs almost twice as fast and has twice the amount of on-board SRAM. If I was going to design yet another audio player, this seemed like a good place to start.

Another motivating factor for a new product was the fact that customers were writing to tell me that they really wanted more than a single stereo output. Indeed, some people were using multiple WAV Triggers not to get more voices, but to get more audio output channels. In addition, people are always asking about audio input, which the WAV Trigger doesn’t support since it only has a stereo DAC.

I started with the following goals based on customer feedback from the WAV Trigger:

  • More voices
  • Seamless looping
  • 8 line-level audio outputs (4 stereo)
  • 2 line-level audio inputs (1 stereo)
  • Reset button for changing microSD card without a power cycle
  • Ability to update the firmware directly from the SD card
  • Dedicated MIDI port so you can use MIDI without additional circuitry

I also thought long and hard about connectors. Everyone seems to want something different – 3.5mm, 1/4″, RCA, direct solder terminals… I ultimately decided to keep it simple and just provide dedicated 0.1″ header for everything. You can either wire directly to another unit or make your own connector/cable assembly. This also keeps both the size and cost down. Same with MIDI – No sense in burdening the board with a 5-pin DIN since not everyone will use MIDI. If you do, you can just cut the end off a MIDI cable, connect two wires to the header and you’re in business.

After selecting a multi-channel audio codec and designing a prototype board, I started porting the WAV Trigger code to get a feeling for the performance capabilities of the new processor.

Mono vs Stereo

Another consideration was that many customers have expressed a desire for support for mono wav files. Stereo is not necessary, or even desirable, for every application. And moving to a mono format increases the output routing flexibility, not to mention the fact that memory-wise I can support almost twice as many voices in mono as stereo. In considering this for the WAV Trigger, I came to the conclusion that supporting mono was too costly from a DSP standpoint. The WAV Trigger’s stereo DAC is actually better served by stereo data – it’s much more efficient because the wav files contain the same interleaved format that the DAC wants. Supporting mono playback in the WAV trigger would very likely have reduced the performance.

Tsunami’s TDM codec, however, wants the channels split to begin with, so the penalty for mono is nowhere as severe. Since Tsunami’s firmware can be updated easily from the SD card, without additional hardware, I decided to provide both mono and stereo firmware versions. (Supporting both at the same time is a bit more complicated, and I’ve provided a way to play stereo content in the mono version.) The stereo version is similar to the WAV Trigger, with 18 stereo voices to any of 4 stereo output pairs. The mono version provides a whopping 32 mono voices to any of 8 mono outputs. A new “Synced Pair” trigger function in the mono version plays 2 specified tracks out adjacent outputs for stereo content. (Yes, they are sample-synced.)


MIDI was an afterthought with the WAV Trigger. By that I mean that when I initially designed the WAV Trigger, I had no inkling that the performance would allow for real-time playability. It wasn’t until I got the latency down to around 8ms and the voice count up to 12 (now 14) that serious MIDI control seemed sensible. While it works great, I had to share the serial port and customers have to construct their own MIDI input circuit (to convert MIDI’s 20mA current loop to logic level serial.) This is a royal pain.

So Tsunami has a dedicated MIDI IN (and OUT, not implemented in firmware yet) with an integrated opto-isolator. It’s a separate UART from the serial control port so you can use both at the same time. The firmware now supports proper use of MIDI Channel, including Omni mode. Even more exciting is a new file-naming convention that lets MIDI users specify the output and looping on a per MIDI note basis. Yes, you can map each key to any of 8 mono (or 4 stereo) outputs.

3.3V Only!

I know, but unfortunately the Atmel SAM S70 is a 3.3V device without 5V tolerant inputs. This means that your first choice in mating it with another microcontroller should be a 3.3V Arduino. Tsunami, like the WAV Trigger, has a pin-compatible header for the FTDI-Basic USB-to-Serial adaptor, but make sure you’re using the 3.3V version! For you modular synth folks, you have to voltage-limit the gate signals anyway, so this shouldn’t be any more of a burden than for the WAV Trigger.

Please use this post to ask questions and provide comments, feedback… whatever.



Update: First panel off the press:



  • reply Christian ,

    This is just great. For my needs, there is nothing to be added. Fantastic, I’m so excited. Can’t wait to get one, put it to work and then expand

    • reply Christian ,

      I was wondering if the SD card slot could be adapted to be enclosure friendlier (thinking of SD card slot like the one they use on “Music Thing Modular- Radio Music”, can be seen on THONK dot co dot uk).
      I want to use Tsunami as a drum/percussion sample player/trigger. Is there a way to organise WAV files in sets or pages of certain numbers like a set of 8 samples (having 8 individual mono outputs), so you could select different sets? If yes, can you select individual WAV files from different sets/pages?
      As an example: the first file in a set/page would always be a kick drum, the second file always a snare drum an so on. If I have sets of 8, 9 would be a kick drum again, 10 a snare drum and so on. That would make it very easy to organise and access samples.
      I hope you don’t mind my brainstorm, I’m just trying clarify for myself how Tsunami will work for me.
      Thanks again

      • reply Jamie ,

        How are you planning to trigger the tracks? Trigger inputs, serial control or MIDI?

      • reply Christian ,

        I intend to get the Tiptop Audio Circadian Rhythm which has 8 trigger/gate outputs

        • reply Jamie ,

          Triggers normally control corresponding tracks 1 through 16. You can assign 2 triggers to be Trigger Bank Up/Down and use them to shift the tracks by 16. Incrementing the Trigger Bank once will map the triggers to tracks 17 through 32, twice to tracks 33 to 48, and so on.

          MIDI Notes are mapped to the corresponding tracks, e.g. MIDI Note 42 to track 42. A MIDI Bank number allows you to shift all the tracks by increments of 128, similar to Trigger Banks. You can control the MIDI Bank either with a Trigger input function or with a MIDI Program Change message.

        • reply Christian ,

          Sorry for incomplete answer, midi will control everything else

          • reply Diego ,

            Hello Jamie!, in fact I was one of those people that bought several wavtriggers for multiouts! I’ve been enjoying wav trigger so much, and now really excited for tsunami, so I’m buying one, I have a couple of questions though
            1. I want to power the tsunami via the 5v power output from an arduino uno, and plug a midi signal generated from the arduino into the dedicated midi inputs, as you said, the tsunami is 5v “intolerable”, but what about the midi and power inputs? could I do what I want, or I need to use a 3.3v arduino uno power output (I’m still new in the electronics field)
            2. Any insight of the price?

            • reply Jamie ,

              Tsunami can be powered by 5 – 15V, so powering from the 5V supply output of an Arduino should be fine as long as it can handle the current. Don’t have an official number for VIN current yet, but should be similar to the WAV Trigger.

              MIDI is a current loop, so if you are driving Tsunami’s MIDI IN from a MIDI OUT, there’s no voltage issue there.

              What you can’t do is apply more than 3.3V to any of the trigger inputs or the serial RX pin.

              Price is ultimately up to SparkFun and depends on their BOM cost. Likely will be in the $79 – $99 range, but don’t want to guess. I should know within a couple of days and will report back.

            • reply Diego ,

              Thanks Jamie for your kind and quick answer, I have a question and some feedback for tsumani
              My question is regarding the MIDI, as implementing a MIDI OUT from the arduino requires 3 leads (TX, GND and 5v) and the MIDI IN in has two inputs, that means that I’ll be connectin the TX and 5v pins of the arduino in the Tsunami, will the MIDI inputs on the tsunami have labels of which lead is which?

              also my feedback is, as Christian said, a more case friendly sd port, also as the tsunami has a MIDI OUT port, it would be great to put a .mid file for MIDI playability so we could use the tsunami as a sequencer for external synths or outboard gear with MIDI out

              Happy Holidays and greetings from Colombia

              • reply Jamie ,

                I’m not sure I understand your statement: “A MIDI OUT from the Arduino requires 3 leads…”

                MIDI is a 20mA current loop and the input is optically isolated. You only need 2 wires from the transmitter to produce the current, in this case TX and GND from the Arduino. From a standard MIDI Controller MIDI OUT, it’s pins 4 and 5 on the 5-pin DIN. I routinely cut the end of a MIDI cable, connect the wires from pins 4 and 5 to a 2-pin rectangular connector and plug it into the MID IN header on Tsunami.

                SD card access noted, although at this point the board design is finalized and you’re talking about a hardware redesign. I’ll keep it in mind, though.

                Regarding your suggestion for MIDI OUT, it’s a good one. What would the requirements be for synchronization between the MIDI sequence playback and any audio the Tsunami is playing?

              • reply Nic ,

                Hey Jamie, just have to say I’m super stoked about the Tsunami! I’ve used a couple WAV Triggers for MIDI-controlled samplers on pedal boards. Love it, and I’m very glad to see audio pin outs on the Tsunami, rather than only the headphone jack.

                Curious what your thoughts might be for this – normally I just use the MIDI channel indicator on my keyboard to tell me which bank I’m in on the WAV Trigger. But it would be cool to be able to have a couple of 7-segment LED displays to show which bank I’m currently in…would that require an external controller like Arduino or Highly Liquid’s MIDI CPU to trigger the bank up/down and to control the LED displays? Thanks!

                • reply Jamie ,

                  Sure. Keep in mind that Tsunami doesn’t map channel number to bank number (nor does the latest version of the WAV Trigger firmware.) I’ve gone to a more traditional MIDI implementation where you can assign Tsunami to either respond to a specific channel number or to all channels (Omni.) In either case, only the MIDI Bank allows you to remap your keys to higher track banks. You can change the bank either with a trigger function (increment or decrement bank) or using the MIDI Program Change message, in which case the program number sent in the message becomes the new bank number.

                  In order to display the bank, you need whatever is controlling it (either via MIDI or a trigger input) to keep track of it and display it.

                  I was doing something similar recently and ordered this for an easy to use numeric display:


                  • reply Nic ,

                    Gotcha – I haven’t updated to the latest firmware, but I will when I have some time to tweak around. Thanks much for the link to the display…I like the idea of triggering the bank changes with footswitches/external controller, and setting MIDI to Omni, rather than how I’ve been doing it.

                    BTW, I’m the random person who made that sample-naming cheatsheet Sparkfun put in their hookup guide…it’s laid out like a piano with corresponding sample names depending on the bank. Not sure if you saw it, just was a handy tool for me, so I figured I’d share it with them.

                    • reply Jamie ,

                      This sample naming sheet is awesome. Would you mind if I included it here on this site?

                      • Nic ,

                        Cool, feel free to share as you will!

                • reply Diego ,

                  Hello, I’m using this schematic for arduino MIDI OUT , https://www.arduino.cc/en/uploads/Tutorial/MIDI_schem.png , where it uses 3 leads

                  About playing .mid archives I suggest sync under 20 ms so we are under the haas effect numbers, but mind, that MIDI is a somewhat unstable in jitter terms, I highly suggest this reading http://expressiveness.org/2012/12/04/midi-jitter and this one https://www.ableton.com/en/manual/midi-fact-sheet/ , but I guess that with the cortex processor, the jitter will be more stable.
                  My idea is to be able to load a song in .mid format, so the tsunami will playback this song via MIDI OUT so I could plug it into a synthesizer and the tsunamiwill play the song (for example in a show that I need my synth playing the notes and I’ll be making adjustments on the filters, envelopes, lfo, etc) a 5 minute song with stable playback, would be awesome. if the midi playback and the tsunami playback sync is under 20 ms, i guess, it will sound in sync.

                  • reply Jamie ,

                    That Arduino MIDI OUT implementation should work fine without the GND connection. +5 and TX going low provides the MIDI IN current.

                    I’ll think about the MIDI sequencer.

                  • reply Christian ,

                    I was thinking about the same thing as Nic, how can you keep track of the bank numbers, but if that display is easy to implement then no more worries

                    • reply Christian ,

                      Nice to see them coming

                      • reply Christian ,

                        Whats the next big thing? To record audio straight into Tsunami? Would be killer

                        • reply Christian ,

                          Hello Jamie, how is Tsunami going? Any release dates? Cheers

                          • reply Dave ,

                            Hello Jamie,

                            I have an application that would involve WAVs that contain heavy DC offsets, with occasional DC-only signals. ls the Tsunami capable of producing such signals? My application consists of a source that produces 5 channels of variable DC voltages – three channels of vary between zero and five volts, and the other two need to swing above and below zero by five volts. I would add external op-amp circuitry to ensure that all signals would work within the limits of the Tsunami, of course. It would be vital that the 5 channels remain in sync when played back.

                            Would the inputs be able to pass DC signals, possibly having to jumper out any input capacitors? How would you see all 5 signals be recorded as generated by the source? My guess would be two channels at a time via ‘stereo inputs’ and use three recording takes, would that work? If so, how might the recorded WAVs be manipulated to ensure they would be in sync? The gaps of silence that will inevitably occur between the starting of the source signals and triggering ‘record’ would be rather difficult to keep consistent – would there be a way to edit them out to keep all WAVs lined up and in sync?

                            Your Tsunami is a versatile and very interesting device, it would be a great addition to a product I have in mind if it can be made to work the way I hope it can. Thanks for any guidance you could offer.

                            • reply Jamie ,

                              The Tsunami is an audio player, and therefore not currently expected to be able to reproduce DC signals. It uses an audio codec, although I don’t see anything in the data sheet that prevents it from outputting a DC offset. There are DC blocking caps in each of the output channels on the board. Furthermore, the output of the DAC is line-level, meaning that you likely won’t get anything beyond 3V peak-to-peak, implying a max DC voltage of around 1.5V.

                              Also, Tsunami’s stereo input does not currently provide for recording to SD media. I don’t anticipate this, as there’s no reasonable way to handle file naming/organization without a UI. I expect that audio is recorded, edited and copied to an SD card using a computer. Given the right audio interface, most PC audio apps are capable of recording 8 channels of audio in sync and saving them as individual mono wav files. As a playback device, Tsunami will start them and keep them in sample-sync.

                              Hope this helps.

                            • reply Bill ,

                              Hi Jamie,

                              I am looking to use the new Tsunami device with a medialon showmaster as my main controller. Do you know of a way to interface this with a show controller that only has 5v serial db9 connectors…. here is the show controller I would be using – https://www.medialon.com/showcontrol/showmaster-le/

                              Thanks for any info.

                              • reply Jamie ,

                                You just need to convert the RS-232 signal levels of the Medialon to 3.3V. You’ll probably need to make your own cable, with something like this on the DB9 end: https://www.sparkfun.com/products/449

                                If you google “RS232 to 3.3V ttl”, you’ll find many similar solutions.

                              • reply Christian ,

                                No problem about recording, was just a thought. Checking daily for release date 😜

                                • reply Jamie ,

                                  It’s been available at SparkFun for over a week now. Check the “Buy” link in the Tsunami menu on the left, or just search on Sparkfun.

                                • reply Christian ,

                                  Oh, dear. I thought there will be an announcement. Thanks Jamie

                                • reply Jonas ,

                                  Very cool project, nice work!!!
                                  I could use this for a commercial project. What are our license options for firmware if I implement this in my audio platform?

                                  • reply Jamie ,

                                    Please contact me directly at info (at) this domain.

                                  • reply Lars ,

                                    Hi Jamie, I’m looking for a way to use Tsunami as a polyphonic, velocity-based sample player. For example, I would like to play a piano sampled in 16 velocity layers (e.g. 128 * 16 samples) via MIDI. What I’d need is a built-in way to map a velocity range to a bank number in order to play the right sample/track. Could you please add such Midi config option? It could simply be a drop-down to select the amount of layers (i.e. velocity ranges) to be used, and then for each note triggered via MIDI, Tsunami could identify the correct track number to be played. Example: With a 4-layer sampled instrument, bank 1 would be mapped to velocity range 0-31, bank 2 = 32-63, bank 3 = 64-95, and bank 4 = 96-127. Therefore, a C-3 played with a velocity of 83 would play track number 316 (C3 of bank 3).

                                    • reply Jamie ,

                                      I’ve had a number of requests for this function, but this is the first one with an explanation of how to make it generic and easy to implement. Great idea.

                                      I assume that velocity should still scale the volume in a linear fashion? If so, then the lower number banks will always be played at a lower volume than the higher number banks. Is this the way it’s typically done?

                                    • reply Lars ,

                                      Yes, exactly. A linear scale would be sufficient. Musicians may prefer a slightly non-linear velocity curve, though, depending on the kind of instrument they are playing. Even though many Midi controllers already offer a way to adjust the velocity curve (either using presets or by adjusting a bezier curve), it would be great if you could provide a config option. Perhaps this page would be of use to you to see how it could be handled: http://stackoverflow.com/questions/41134365/formula-to-create-simple-midi-velocity-curves

                                      • reply Jamie ,

                                        Both the WAV Trigger and Tsunami are already responding to velocity by linearly scaling the target gain. I would, initially at least, leave this as is, and just divide the velocity into zones and map banks accordingly.

                                      • reply Gerhard ,

                                        Hi Jamie,
                                        Recently bought a Tsunami to replace other samplers I’ve found to limiting because of low number of physical outputs and low number of samples supported. It’s pretty rare to find a sampler with 8 outputs these days and Tsunami might fit the bill. I would like to see however support for multiple midi channels. Ideally, a map for a MIDI bank for each channel. this would make the Tsunami massively more versatile. One could for example implement 16 banks of 128 samples. Or a multitimbral orchestral instrument. I think you note above it was a conscious decision not to go this route but since it’s just a generalisation of the present implementation people would still be free to use a single channel only.

                                        • reply Jamie ,

                                          This is a great example of how hard it is to meet everyone’s needs. The WAV Trigger behaves as you describe, with the MIDI Channel acting as a bank number. I had a number of requests to change this for Tsunami so that it behaves more like a standard MIDI module, responding either to one MIDI channel (with Program Change to change banks) or to all (Omni).

                                          • reply Gerhard ,

                                            right … didn’t look too much into the wav trigger i have to admit. well perhaps it could be a third configuration parameter for the global MIDI Channel option? single channel, OMNI, or bank mapped?

                                        • reply Roman ,

                                          Hello, Jamie.
                                          I’m building the sound system for escape room (some kind of maze with the riddles, if you never heard about it).
                                          This system will provide the musical background for the game process, and in the same time it will be the communication system for the game operator to talk to the players inside of the room, so I have some microphone connected to the same output with the music output. For escape room with one theme we have for example 3 rooms, and for each room I need to play different music. Sometimes we have 9 different tracks in one building, and I need them playing simultaneously from the one sound system. Thats why the Tsunami is perfect for me!
                                          But when I make some test projects I got some static noises from my speaker with amplifier and the sound wasn’t clear…
                                          I talked to SparkFun support, but we couldn’t find some solution…
                                          So hope you can help me with it.
                                          Here is some scheme of how is my project looks like
                                          If you need some more information to understand situation, I’ll send you everything you need.
                                          Thanks for you attention.

                                          • reply Jamie ,

                                            Please try to isolate the problem. Does Tsunami work and sound properly by itself if you use a single amplifier or headphones? Go through the hook-up guide to make sure there’s nothing wrong with your unit, then determine at what point things stop working properly. Simply telling me that there’s static and that the sound isn’t clear after you run through all those audio stages doesn’t give me enough to go on.

                                            • reply Roman ,

                                              It works properly only if I connect it directly to the speaker with builtin amplifier or headphones. But if I put any amplifier in the same power circuit with Tsunami and start track playing, in this moment it starts to make noises. When the track is not started there is no noise.
                                              If I connect them to the different power modules but with the same Ground it reduce the noise, and now I found one solution how to reduce noise almost to zero, I did the video for the SparkFun tech. support, if you could look through it, maybe it will make something clear.
                                              Please don’t pay attention on the name in the start of the video, it was addressed to Chris from tech. support… :-)))

                                              • reply Jamie ,

                                                I think you may need to rethink your analog connection strategy. Someone with better knowledge of the external components writes:

                                                “Those little mono amp breakouts can be tricky. They’re a differential input, 250 kHz class-D power stage, and a bridged output, intended to be tied to both ends of a loudspeaker. From an SE input, the “-” input needs to be tied to ground. The “-” output mustn’t be grounded. From the video, it looks like you’re trying to use them for general-purpose voltage gain? Then following them with an amplified speaker? I’m not sure that’s going to work very well.

                                                It looks like you’re trying to combine signals from the mic and Tsunami at the output jack? Effectively the class-D output is driving the Tsunami output, and vice versa. The series RC’s on the Tsunami output are the only thing between them. I’d recommend using a couple 10K resistors as a passive summing network, at the least.”

                                          • reply Bernd ,

                                            Hi Jamie, in the product specification of the WAV Trigger Board you mentioned the SNR of the audio output. It seems to be missing in the specifications on the Tsunami WAV Trigger Board. Probably because they are the same between the boards, but it seems like important info for people that are not familiar with the original board.

                                            • reply Robyn Farah ,

                                              I am playing with the Tsunami (obviously) and I had a few questions:
                                              – The 16 inputs are digital, I want to use them with analog sensors, can MIDI do this? I may be more work than just using and Arduino, Pi or Bela. The thing with this board is the 8 mono audio outputs
                                              – Can I assign a trigger to a speaker?
                                              – Can I assign multiple triggers to one speaker?
                                              – Can I assign multiple sounds (wav files) to one trigger?


                                              • reply Jamie ,

                                                I’m not sure I completely understand your questions. The trigger inputs are digital, and Tsunami has no analog control inputs. I’d suggest using an Arduino (Teensy, for example) to read and process analog sensors, and use the Tsunami Arduino Library to control the Tsunami from one of the Arduino’s serial ports. This would provide the most flexibility.

                                                Maybe if I understood better what you are trying to do I could be more specific.

                                                By “speaker” do you mean output? I believe the answer to all your questions is “yes”, but I suggest if you haven’t done so already, download and run the Tsunami Configurator app and experiment with the trigger settings. I think that, plus the online user guide and the SparkFun hookup guide, should answer most of your questions.

                                              • reply MZ ,

                                                Man, Tsunami looks cool! I’ve seen the WAV trigger Mellotron setup, and it seems perfectly suited for that kind of thing (and about a dozen other ideas that keep popping into my head.)
                                                One thing that would be super cool, and I just never see devices be able to do this:
                                                Play all of the available voices in a synced loop perpetually, then use either MIDI or trigger ins (preferably the former) to “gate” the voices, rather than trigger the samples to start. In essence, I’m thinking of the Optigan. Seems like the natural progression from the Mellotron paradigm. Then use an extra output to drive an LED like the Optigan’s “metronome” feature. If I’m missing how to pull this off with Tsunami, please let me know. I’ll be dropping an order for this thing soon, anyway. Very cool!

                                                • reply Jamie ,

                                                  While this is not a built-in feature, it would be quite easy to implement using an Arduino Teensy. The Tsunami Arduino Serial Library allows you to preload a bunch of looping tracks and then start them all at the same time. Assuming they’re all exactly the same length, they’ll stay in sync forever. (You can also start up to 8 looping tracks in sync with a trigger input.) They can be routed to the same output or different outputs in any combination. The Arduino Serial Library also provides controls for individual track volumes, including built-in fades. So all the Teensy would need to do would be to convert incoming MIDI Note-On/Off messages to outgoing Tsunami Track Volume/Fades. I believe the Teensy has a MIDI library, and it’s a good choice because it has multiple serial ports.

                                                • reply MZ ,

                                                  OK, I’m going to have to look into that. Thanks!

                                                  • reply NAJ ,

                                                    I’ve got a very affordable MIDI controller keyboard [ACORN 61Keymaster] that does not have a jack for expression/volume pedal. Any suggestions on how to connect a pedal to the TSUNAMI, (which is great!) to activate expression for the lowest cost. This is so that it can be used in a project to introduce children to read, write and play music, so keeping the overall cost down makes it possible for more and more children to participate.

                                                    Thanks to you and Sparkfun for making this possible through the TSUNAMI!

                                                    • reply Jamie ,

                                                      Tsunami doesn’t yet implement any analog input control, so the only way to control parameters such as volume and pitch bend is through MIDI or the serial control protocol. If you’re already using a MIDI keyboard on the MIDI port, you’d either need to find an expression pedal that outputs MIDI and then somehow merge the MIDI streams, or connect an analog expression pedal to an Arduino and use the Tsunami Arduino Library to control the parameter based on the analog input. Keep in mind that Tsunami does support MIDI sustain, so if your keyboard has a sustain pedal jack, at least that should work.

                                                      • reply NAJ ,

                                                        Thanks, Jamie!

                                                    • reply Toby ,

                                                      I am looking for something that can play a wav file once on power-up (without any other interaction) for an art installation. Can the Tsunami auto-trigger on power-up? Maybe if I hard wired one of the triggers to ground? Or perhaps with an Arduino or Teensy that sends a serial message a short time after power -up?

                                                      • reply Jamie ,

                                                        Yes. You can either wire a trigger input to ground and set the trigger properties to “loop”, or you can do it without any hardware mods by setting a trigger properties to “level” and “invert.” In either case, the track will start automatically and loop until something else stops it. Hope this helps.

                                                      • reply David ,

                                                        I’m considering using the audio input and blend this ‘live’ sound with a pre-recorded WAV. There doesn’t seem to be much info on using the inputs. Can I, for example, fade them up and down (or control gain) and assign them to specific outputs using serial control?

                                                        • reply Jamie ,

                                                          At the moment, the only thing you can do is select which output(s) you would like to mix the incoming audio to. This can be any or all of the 4 stereo output pairs. You do this via the init file using the Tsunami Configurator app – there is no currently serial control, and any gain adjustments need to be done externally prior to the input.

                                                          I haven’t really had enough feedback regarding potential uses for the audio input to warrant spending any time developing for it – haven’t thought of the “killer app” use. I don’t consider recording a viable option; the lack of user input makes things like track number/naming and editing problematic.

                                                          I could probably add input gain control via serial control pretty quickly if that’s of any help.

                                                          • reply David ,

                                                            Thanks for your really quick reply and sorry for the delay in mine. Thanks too for the thoughts.

                                                            As it happens, being able to transfer a WAV to the SD card over serial or audio in would be perfect for my application as it would make the whole installation remotely administerable – although it’s probably a fairly niche set of circumstances.

                                                            I’m going to be using a RaPi to feed audio in so could of course build some gain control in there – but if it were possible, serial gain control (and possible output pair selection) on the Tsunami would be a much neater solution and allow things like muting the channel when not in use.

                                                            • reply Jamie ,

                                                              Transferring audio over serial is impractical due to the limited baudrate of the serial connection. Recording audio is impractical because of the inability to name and otherwise manage filenames without a user interface.

                                                              My plan with Tsunami was to support Mass Storage Device over USB, so Tsunami would appear as a drive and you could drag files to it, but due to a bug (they call it an “errata”) with the Atmel SAM S70, you can’t support both USB and normal audio sample rates like 44.1k and 48k at the same time. With USB, the audio would be ever so slightly out of tune. Perhaps when Atmel releases a rev B next year, USB transfers will become feasible.

                                                              • David ,

                                                                Yes, a USB mass storage option would be a powerful addition. I’ll keep me ear optimistically to the ground for this.

                                                                Do you think that you might include the serial channel selection and volume control you mentioned for the audio in in a firmware update in the near future?

                                                        • reply NAJ ,


                                                          So I have this BOSE Compact L1 and when I plug audio from the Tsunami (which I love, incidentally) I get a hum. I’ve increased the audio level of the samples to reduce the amount of hum, but it is still there, at a much lower level? Using RCA jacks to input the L + R. Tried isolation transformers, with no change. I am sure that there is a simple explanation and solution, but can’t come up with it myself! Thanks again for creating this incredible device!

                                                          • reply Steve Roberts ,

                                                            Hi Jamie,

                                                            Looking forward to making a new instrument with this board which I received last week.

                                                            I’ve only just managed to get a first play with it. A couple of things. Firstly all your links on the download page are giving me a 404 error ?

                                                            The other issue is that I’m getting quite a bit of digital noise if I use my my bench power supply when connecting to the VIN pins or connecting the computer’s USB power to the micro USB input. Using a battery is fine. I’ve noticed that the noise only happens once I play a sample and noise remains for say 6 seconds after the sample has finished ? I’ve been using your piano samples from the Wav Player as a test.


                                                            • reply Jamie ,

                                                              Thanks for the alert about the 404 errors. It’s site-wide, including the other download pages, so I strongly suspect something changed on my host side. Will look into it and get it fixed as soon as I can. Will probably be later today.

                                                              Regarding the noise, I recall that the SparkFun engineer who helped with the hardware design encountered something similar but only with a particular bench supply. We did do noise measurements, and what you’re seeing is definitely not normal. You don’t mention how you are listening or measuring the output… are you plugged into a powered amplifier, or listening with headphones?

                                                              I’ll review my emails with him to see if anything pops out.

                                                            • reply naj ,

                                                              The hum problem is solved! Recording at the highest level and just popping the volume control a tad on the Bose solves the problem.

                                                              A new problem appeared just now. The MIDI In suddenly stopped reading – there is MIDI signal going to it (I have an LED I rigged up for troubleshooting). This is not the first Tsu that has done this for me. Any suggestions would be greatly appreciated. Thank you!

                                                              • reply Jamie ,

                                                                I’d need a bit more information to be able to help troubleshoot your MIDI issue. You say this has happened before. Does it ever start working again, or does it become permanently disabled? Does a power cycle fix it?

                                                                What’s doing the sending? How exactly did you hook up an LED? Does it work if you remove the LED? Do you have any other MIDI Controller available to test with?

                                                                Is Tsunami set for Omni or a particular MIDI channel number? Are you sure that you’re sending on that channel?

                                                              • reply ~!~!~! ,

                                                                I’m not sure if I’m running into a bug.

                                                                I’m running the board in mono mode, and when I trigger these from the .ini file… I get the expected result

                                                                TRIG 01, 208, 0, 0, 1, ,
                                                                TRIG 02, 208, 0, 1, 1, ,
                                                                TRIG 03, 208, 0, 2, 1, ,
                                                                TRIG 04, 208, 0, 3, 1, ,
                                                                TRIG 05, 208, 0, 4, 1, ,
                                                                TRIG 06, 208, 0, 5, 1, ,
                                                                TRIG 07, 208, 0, 6, 1, ,
                                                                TRIG 08, 208, 0, 7, 1, ,
                                                                But only the first four of these Tsunami Arduino Serial commands sound from the correct channel

                                                                tsunami.trackPlaySolo(1, 0, false); —>outputs to 1
                                                                tsunami.trackPlaySolo(1, 1, false); —>outputs to 2
                                                                tsunami.trackPlaySolo(1, 2, false); —>outputs to 3
                                                                tsunami.trackPlaySolo(1, 3, false); —>outputs to 4
                                                                tsunami.trackPlaySolo(1, 4, false); —>outputs to 1
                                                                tsunami.trackPlaySolo(1, 5, false); —>outputs to 2
                                                                tsunami.trackPlaySolo(1, 6, false); —>outputs to 3
                                                                tsunami.trackPlaySolo(1, 7, false); —>outputs to 4
                                                                any help would be awesome

                                                                • reply Jamie ,

                                                                  Sounds like a bug. I’ll look into it and post what I find here. Might take me a day or two.

                                                                  • reply Jamie ,

                                                                    Looks like the bug is in the Tsunami Arduino Library. I’ll fix it and commit an update when I get a chance, but in the meantime, it’s easy for you to fix. In the “Tsunami.cpp” file, look for the routine “Tsunami::trackControl(int try, int code, int out, int flags)”. Change the first line of code in that routine to:

                                                                    o = out & 0x07;

                                                                    That should do it.

                                                                  • reply ~!~!~! ,

                                                                    Hi again…
                                                                    I think I found it.
                                                                    #define TSUNAMI_NUM_OUTPUTS 8

                                                                    Tsunami.cpp (master vol, track control, sample rate)
                                                                    o = out;
                                                                    //o = out & 0x03;

                                                                    • reply ~!~!~! ,

                                                                      Your solution was all that was required…
                                                                      “#define TSUNAMI_NUM_OUTPUTS 4”
                                                                      works fine too


                                                                      • reply ~!~!~! ,

                                                                        Can we program the inputs?
                                                                        I was looking for something like:
                                                                        tsunami.input(0, 0, -12);
                                                                        tsunami.input(1, 0, -3);
                                                                        tsunami.input(1, 7, -12);
                                                                        Or a way to do it in the .ini file?


                                                                        • reply Jamie ,

                                                                          The only function supported currently is to mix the incoming stereo signal into any or all of the outgoing pairs (1/2, 3/4, 5/6 and 7/8). This is done via the init file using the check boxes in the Tsunami Configurator app. There is no input gain control, so you’ll need to adjust signal level before Tsunami’s input.

                                                                        • reply ~!~!~! ,

                                                                          thanks for your reply…
                                                                          Could you add discrete control of the inputs?
                                                                          Discrete control would allow summing to mono, splitting to stereo, muting the inputs, outputting to non-adjacent outputs, outputting to multiple arbitrary outputs.

                                                                          Muting the input seems like something that should be available via trigger pins.


                                                                          • reply Steve ,

                                                                            Is there a way to add a tuning control to a tsunami other than using serial control? If you plan to implement analog inputs in future, a tuning control would be a useful for stand-alone use.



                                                                            • reply Jamie ,

                                                                              Sure, but can you be more specific? Tsunami has either 4 stereo or 8 mono outputs that each have independent pitch control. Only 4 of the 16 trigger inputs can be used for analog input. How would you propose that it would work?

                                                                            • reply Ben ,

                                                                              I’ve been using the older WAV shield for a project, and I’m thinking about upgrading to a Tsunami in order to mix incoming music with WAV-driven sound effects. I’ve read that this is possible, but I’m having trouble finding info on controlling/mixing audio input via (Arduino) serial communication. Could you point me towards the right spot to learn about this? Thanks!

                                                                              • reply Jamie ,

                                                                                The current firmware only allows you to select which outputs to mix the inputs to. This is done using the Configurator app and the init file – it’s not something that can currently be controlled through the serial protocol. If I enabled serial control of input routing, I’d also have to implement volume ramping, since without that there’d likely be a click or pop when changing the routing.

                                                                                Currently the 2 input channels can be routed and mixed to any combination of the output pairs: 1/2, 3/4, 5/6 and 7/8. There is currently no gain applied o the input so you have to adjust the volume at the source.

                                                                                It always helps if you can explain exactly what you’d like, since there’s often many ways to achieve something. Some easy, some hard…

                                                                              • reply Steve ,

                                                                                I was thinking of a global tuning control. Using the board as a stand-alone midi instrument, the voices/samples would presumably be in tune with each other, but it would be necessary to be able to tune the whole tsunami (all outputs) to be in tune with other instruments/musicians.



                                                                                • reply Cory ,

                                                                                  Hello Jamie, I just purchased a Tsunami and am impatiently waiting for it to arrive in the mail… until then, I’ve been making my enclosure and getting the hardware components in place. I am really excited to have a MIDI sample player! It’s not an easy thing to find, having 8 outputs. I have a couple of questions:

                                                                                  If I want to control the volumes of each output, how simple is it to hook up a potentiometer? Is this something I would have to do with my Arduino, or could I simply put a fader between the output signal and the output jack?

                                                                                  So this is constrained to a single MIDI channel, is there hope or possibility of being able to use multiple channels in the future? My goal with the sample player is to trigger via MIDI my kick sequences on Channel 9, snare sequences on Channel 10, etc. The way the Tsunami is now, I would be using one MIDI channel for everything, correct? Also, can the MIDI Out function as a Thru?

                                                                                  Is the sequencer idea you mentioned feasible and possible anytime soon? That would really be amazing!

                                                                                  For the loops on the Tsunami, are they synced to the incoming MIDI clock? How exactly would I set the loop time, is it simply sample length?

                                                                                  Sorry for all of the questions, thanks for the awesome product!

                                                                                  • reply Cory ,

                                                                                    I apologize for the multiple messages…

                                                                                    If I want to hook up a power LED, and possibly even an LED for incoming MIDI, how would I go about doing that? I assume for the MIDI I would just stick the LED in series between the MIDI In jack and the holes on the board?

                                                                                    • reply Jamie ,

                                                                                      Some of your questions are either about basic electronics or are answered in the Tsunami documentation, including the User Guide on this website, the SparkFun hookup guide and the Arduino Library example sketch. Unfortunately, I don’t have the ability to help with individual projects, so I suggest you post on the SparkFun forum where there are many people willing to provide some guidance. Some specific answers:

                                                                                      No MIDI Thru function currently.

                                                                                      Loops are not synchronized to anything external. If you start multiple loops with at the same time, they will stay in sync.

                                                                                    • reply Harry ,

                                                                                      Hi Jamie –

                                                                                      Great board- but I’m curious if there is a way to use the Tsunami as an “audio interface” – processing 8 output channels from a computer…


                                                                                      • reply Jamie ,

                                                                                        Nope. Tsunami is designed to be a polyphonic, multi-output sample player, playing wav files stored on the microSD card. It does have a stereo audio input and allows you to mix incoming 2-channel audio to any or all of the 4 output pairs, but no signal processing as yet.

                                                                                      • reply Giani ,

                                                                                        Hey Jamie,

                                                                                        I am wondering if it is possible to write to the on board sd card using arduino code and the sd.h library. If so, how owuld I go about wiring the pins to transmit data to the sd card?

                                                                                        • reply Jamie ,

                                                                                          It’s not impossible, but certainly beyond the scope of any help that I can provide. You can’t just drive the SD card from two sources without a way to switch. This would involve major modifications to the Tsunami hardware.

                                                                                        Leave a comment