-
Notifications
You must be signed in to change notification settings - Fork 95
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implemented Sysex Coalescing #200
Implemented Sysex Coalescing #200
Conversation
This looks like it's shaping up to be a great PR. I've noticed you continuing to work on it (which is great). Please ping me when you think it's ready to merge. Also, if at all possible, some kind of test harness for it would be great. If you can write a program that exercises it without any extra hardware, that would be ideal. Even if you can just describe how you're testing it and which hardware you're using, that would be great too. |
@armadsen Thanks! Yeah it's finished. I'm already using 0af5172 in production for Juno Editor v2.2 because one client had chunking issues on his “usb to midi cables” interface. |
Simplified my approach to checking for invalid data, as I was being overly cautious about it. Also, when EOT is found before the end of packet data, I am not parsing remaining data of packet anymore: One packet = one logical unit of data. Assuming we will find sysex + other commands inside a single packet is kinda going overboard. If a packet contains invalid sysex data (after its start byte), i believe that's not the framework's job to do extensive sanitizing. The current code is built around the following assumptions:
hence:
|
Note: re-wrote packetList handling to be block-based so I could test time-out properly. This accidentally lead to even better code… tests are awesome! @armadsen Finally ready to review :) |
Finally got this reviewed and merge. Looks great, thanks so much! |
References Issues #198, #122
Alternative Implementation to PR #130
Safeguards:
EOT = End of transmission marker 0xF7
Took some hints from SnoizeMIDI Source