Midi To Arduino

Convert a raw midi file for use to play on an Arduino (via the tone function)/Raspberry Pi (via the GPIO pins). (Midi to Tone)

Select a midi file:


Choose a url:

Additional Notes

Note that this is a low-level monophonic note/frequency conversion from midi to tones.
This webapp does not allow for an Arduino to be able to play a full midi (although, with multiple Arduinos you can achieve something to that effect).
Also requires a Piezo buzzer. Speakers have not been tested.

Currently supported

  • Midi to Raspberry Pi Tone (Python, GPIO)
  • Midi to Arduino Tone (C, Tones. Uses PWM digital pins)
  • Midi to Arduino Tone with Protothreads (for Arduino, enables for pseudo-"multitasking" of Arduino runtime. i.e. do other stuff simultaneously alongside the buzzer)
  • Midi to Windows (Python, winsound)
  • Midi to Raw Tones (for custom requirements)


Is there a way to convert MIDI files to tones an arduino can read and play on a piezo? - /r/arduino

Example Source Output

https://gist.github.com/extramaster/869a1db94281309eafa7 - ArduinoChristmas.ino

Makers Hub

What did you make with this? Submit a YouTube link!