Skip to content
Python-based MIDI to G-code scripts derived from Tim Gipson's awesome mid2cnc This version supports the MakerBot Cupcake CNC 3D Printer.
Branch: master
Clone or download
Type Name Latest commit message Commit time
Failed to load latest commit information.
samples New Kraftwerk sample files Jun 2, 2010
README Bug fix for absolute movement and resulting slow song Jun 2, 2010
mid2cnc_readme.txt Inital import Jun 1, 2010


This is a hacked version of Tim Gipson's awesome mid2cnc code to support the MakerBot Cupcake CNC 3D printer. The gcode file will voice the song in the Z axis only.
mid2cnc requies a MIDI file, and I've found that this workflow is effective on OS X 10.5.8, YMMV:

1. Obtain the song you want as a PowerTab guitar tablature file. Search for .ptb or gp4 files using your favorite search engine
2. Use Tablatures or other application to convert tablature file to MIDI file
3. Use mid2cnc to convert MIDI file to gcode file.

python ./ midifile gcodefile ppi
python ./ ../man_on_the_silver_mountain/man_on_the_silver_mountain.mid ../man_on_the_silver_mountain/man_on_the_silver_mountain.gcode 800

You may have to experiment with the ppi value to get the song right; 600 is a good place to start. Larger numbers make the pitch lower and the song slower.

mid2cnc - (Also read the mid2cnc_readme.txt file)
PowerTab files -
MakerBot Music group -
MakerBot Music -

Slowhand ( for the "Man On The Silver Mountain" source PowerTab file
Aladin for the "Tour de France" source guitar tab file
And last, but not least, T. R. Gipson (drmn4ea at google mail) for the awesome mid2cnc code on which to hack.
You can’t perform that action at this time.