Hey guys. I am using the MIDI handler routine from the Pod examples for my clonewheel organ project. It works perfectly when I use my Korg TR workstation MIDI Out as a keyboard.
Now the odd part: This workstation has an “audition” function that plays a few bars of a song so you can hear any of its built-in patches. Their MIDI sequences are played out as well - nice for me since I can’t play a lick on a keyboard! Some of them play fine, but a few leave one or more “stuck-on” notes. I can turn them off if I hit the key of the stuck note again, as the code will correctly process it and turn the note off. I have seen as many as 8 notes stuck on by a particularly “dense” MIDI sequence. So it seems like some Note-Off messages are not being handled.
I am only looking at Note-On and Note-Off messages, ignoring anything else. I keep a 32-entry note table, add to it with the On’s note value, and search and delete them when I get the Off’s. I process at the 1ms callback rate. With 32-way polyphony, I can literally lean my arm on the keyboard and all the notes turn on and off as expected.
So the question is, is the MIDI handler routine in the HID library robust, i.e. can it handle incoming messages at the maximum rate, and ignore all the messages that it is supposed to ignore? Looking through the “maze of twisty passages” that are the libraries, I see that the handler uses a 256-entry event FIFO. I can’t imagine that it is overrun.
Any ideas? This isn’t a show-stopper for me, but I assume that others might want to drive their Daisy synths with MIDI sequencer apps that could could overwhelm the handler in this way.