Description
Great! I have been searching for a midi-parser since quite some time now.
But: I already know that it will fail on devices with limited memory, since the parser will load the complete midi into memory and then sort it.
So the idea would be to add a method to the parser that allows it to dump the pre-parsed (and time-sorted) notes to a file. That file could then be fed into the player using an asyncio generator. The first step could run on a Pi (no memory constrains), the player would then run on e.g. Pico.
I have a project (https://github.com/bablokb/cp-buzzer-music) that has some clumsy manual instructions to convert a midi to a suitable format for asynchronous processing. So if I find some time I will try to integrate your midi-parser instead.