Go Down

Topic: Understanding the parameters in the sysexCallback of standard firmata (Read 618 times) previous topic - next topic


I am trying to extend standardFirmata to control some custom hardware. I've been reading up on firmata and I understand I can use sysexCallback to send custom commands and handle the setup form there. My understanding is that the firmata reads data in from the serial and sends the data to sysexCallback to be handled. The data I send needs to be in 7 bit packets, from least to most significant. It also must be in this format:

[7 bit SESEX_START | 7 bit command | variable data in 7 bit chunks LSB - MSB | SESSEX_END]

I think most of this makes pretty good sense. What I am struggling on is that the sysexCallback method in the arduino sketch has this signature

sysexCallback(byte command, byte argc, byte *argv)

command is the second 7bit packet, I think argv is the variable data, what is argc?


Without knowing a single thing about standardFirmata, I would venture to say that argc is the count .

Go Up