Convert MusicXML to PIC assembler for running on the Boldport Club Stringy.
About the Stringy
The Stringy was Project #14 from June 2017, and is a remix of MadLab's 'Funky guitar'.
StringyFi is a simple gem that converts MusicXML source files to a PIC assembler source format that can be compiled and programmed to the Stringy.
See LEAP#349 DemoBurner for a complete example of this in practice.
StringyFi has some serious limitations, some of which are in its implementation of MusicXML parsing, some are fundamental limitations of the Stringy. I have found that most scores need tweaking to be reproduced acceptably on the Stringy, and some are just too complex (without re-writing the Stringy firmware en-masse). Some key points to note:
- The String uses ony 2-bit (4 levels) of note duration, so the conversion squeezes the score into 4 note durations as best as possible
- many notation features ignored: slides, ties etc
Add this line to your application's Gemfile:
And then execute:
Or install it yourself as:
$ gem install stringyfi
The StringyFi executable accepts a file path to the MusicXML source to convert, and emits the assembler source on STDOUT (so it can be redirected as appropriate).
$ stringyfi ./spec/fixtures/music_xml/chromatic.xml > ../CustomDemo.X/demo.tun
The spec/fixtures contains a few examples that are also used in tests.
- Fork it
- Create your feature branch (
git checkout -b my-new-feature)
- Commit your changes (
git commit -am 'Add some feature')
- Push to the branch (
git push origin my-new-feature)
- Create a new Pull Request (6. Join Boldport Club!)