Home Forums Sparkfun MP3 Shield Library Support Forum Introduce sounds or alter the sounds of bank GM1,GM2 in vs1053 MP3 Player Shield Reply To: Introduce sounds or alter the sounds of bank GM1,GM2 in vs1053 MP3 Player Shield

#2968

I have unfortunately the past few months been swamped with my day job. I never quite finished the above. Curiously I am not a musician and don’t know much about Midi and such. I got stopped on getting the MIDI file. Note that the VS1053 will read in the stream and auto decode it. So while decoding a MP3 or wav stream from file, One can simply stop the current file position and then optionally flush the current VS1053 buffer as to stop immediately. And then send it any other stream. My idea is that MIDI files of a single note for the bell instrument will be short. and go into the VS1053 buffer. It a single not would be short enough that it can be stored as an array in flash with only few dozen bytes. This relieves the need of opening another SdFile or changing the file pointer, etc….

So just need a MIDI type 0(zero) file of a single key board beep or alike. Use the Pause command with the flush Pre or Post (which ever is quicker) send the MIDI array and then resume the file. The VS1053 buffer will simply queue up the stream and play what it decodes.