Generative Music
Generate MIDIs from data. [github]
This repo takes data and transforms it into midi files (uses midiutil library). MIDI files are then transformed into .wav audio with fluidsynth and a soundfont.
Currently the transformation of the input data is a basic linear transformation. In my case, the data is from temp and humidity sensors running on a Raspberry pi. The RaspberryPi repo shows an example of source data.
That same repo also has code to
create a hyperlocal FM radio station that can broadcast media files.
Playing Sounds:
To play the music, you will need:
- The ability to play MIDI files (it appears Mac OS can no longer play MIDI files by default. You’ll need FluidSynth (you can brew install fluid-synth.
- A Sound Font to actually play the MIDI file (you can chose which instrument). I’ve included an open-source piano in the repo: there are tons of instrument options out there.
The most up-to-date code is in the feature/csv_readings
branch.