I’m trying to send SysEx messages to my Yamaha THR10 amplifier. I’ve got things partially working, but I’m trying to improve on it.
So far, I can send simple messages for individual parameter changes since they don’t utilize a checksum byte. I would however, like to be able to send block update messages to completely change the amplifier state with one message. This uses a much longer message with a checksum byte at the end. I used jazzundso’s code snippets in this post to figure out how to use the SM_ commands.
So, a couple of questions:
1.) What is the purpose of the “#” in the SysexMessage assignment statement? Is it a type identifier? Or a data formatting operator?
2.) My experiments indicate that SysexMessage doesn’t look like an extended array or string base type. SM_ChangeValue lets you change a value at an index within a SysexMessage. How does one retrieve values at specific indicies within a SysexMessage?
3.) I’ve looked through the language introduction pdf, and it mentions that all of the “usual” boolean operators are available, but doesn’t go into syntax for any of them. Since I am trying to execute a checksum algorithm (I think it might be SY77/SY99), I will need to be able to perform bitwise comparisons (at least XOR and AND, I believe) on byte summations. Does GPScript have the ability to do any of this?
4.) Am I making this too hard on myself? Is there functionality built into or planned for the SysexMessage and/or SysexManager types?
I know GPScript isn’t meant to be a fully featured language, but if it’s going to fully support SysEx, then I’m hoping there’s a way to make simple checksum algorithms work?