Closed PusherLabs closed 8 years ago
howdy-
just pushed a small addition to VVMIDIMessage that will hopefully make it easier to work with sysex data:
uint8_t sysexVals[] = {0x00, 0x01, 0x02, 0x03};
NSData *sysexData = [NSData dataWithBytes:sysexVals length:4];
VVMIDIMessage *sysexMsg = [VVMIDIMessage createWithSysexData:sysexData];
[outputNode sendMsg:sysexMsg];
I came up with some working code just prior to your response:
VVMIDIMessage *sysexMsg = nil;
NSMutableArray *sysexArray = [[NSMutableArray alloc] initWithCapacity: 0];;
char sysexDump[] = {0xF0, 0x00, ... etc.};
for (int i = 1; i < x; i++) {
[sysexArray addObject:[NSNumber numberWithChar:sysexDump[i]]];
}
sysexMsg = [VVMIDIMessage createWithSysexArray:sysexArray];
[midiManager sendMsg:sysexMsg];
Before you ask, sysexDump[] contains a whole series of dumps, that I can cherry-pick and send individually, so I'm picking out sections between the 0xF0 and 0xF7 delimiters.
But now I have a question. Is there any advantage to sending data to a valid Node versus just using VVMIDIManager as I have above?
But now I have a question. Is there any advantage to sending data to a valid Node versus just using VVMIDIManager as I have above?
nah- sending it to the manager just sends it to more places (all destination nodes + the manager's built-in virtual node)
Thanks man!
Can you point me toward any SysEx (sending) examples or sample code?