arraytostring not behaving as expected
Posted: 17 Jan 2013 11:34
My template (EvolverProgrammer.jzml - attached) receives a 226 Byte SysEx dump in function ReceiveState(MIDI_ARGS) then uses a function ArrayToHex(array) to convert 8 Bytes to hex, and then return them as a string using arraytostring. This string is then displayed on a monitor object.
Since I only do 8 Bytes at a time (this is the "packet" size for the DSI Evolver) I need to make multiple calls to ArrayToHex(array).
PROBLEM: the 15th call to ArrayToHex(array), and every call after that returns 0. The reason I think it's an issue with arraytostring() is that if I modify ArrayToHex(array) to do all the munging but then just return the decimal values, i.e. not call arraytostring(), everything works fine.
I've been working at for a while and am a bit stumped - anyone got any ideas? Am I doing something obviously stupid? I can work around it for now, but it concerns me that I don't understand why it's not working - it might come back to bite me!
Attached are the template file, and a sysex dump (SysExDump.jzml) I've been using to troubleshoot (you need to change the extension to .syx as there was an issue uploading a .syx file). You can use this free program to send the sysex to Lemur: http://www.snoize.com/SysExLibrarian/
thanks!
Since I only do 8 Bytes at a time (this is the "packet" size for the DSI Evolver) I need to make multiple calls to ArrayToHex(array).
PROBLEM: the 15th call to ArrayToHex(array), and every call after that returns 0. The reason I think it's an issue with arraytostring() is that if I modify ArrayToHex(array) to do all the munging but then just return the decimal values, i.e. not call arraytostring(), everything works fine.
I've been working at for a while and am a bit stumped - anyone got any ideas? Am I doing something obviously stupid? I can work around it for now, but it concerns me that I don't understand why it's not working - it might come back to bite me!
Attached are the template file, and a sysex dump (SysExDump.jzml) I've been using to troubleshoot (you need to change the extension to .syx as there was an issue uploading a .syx file). You can use this free program to send the sysex to Lemur: http://www.snoize.com/SysExLibrarian/
thanks!