Sunday, March 26, 2017

Mtof Library for Arduino

The mtof library for Arduino converts MIDI pitch values to frequency values and vice versa.

Usage is via two functions: mtof.toFrequency(pitch), which returns the frequency of an input pitch, and mtof.toPitch(frequency), which returns the MIDI note number of an input frequency.

All calculations are done as double floats.

Download the library and examples here: