I have a Spark Switch Pro running firmware 0.5, and the switching aspect of it appears to be working fine. I can successfully connect it to Powerbox terminal using a JETI adaptor and set the telemetry to JETI.
I am trying to integrate the Spark Switch Pro with some autopilot software running on a Raspberry Pi through the JETI USB adapter. I set my serial driver to 8 data bits, ignore parity (so that I get the nine data bit framing JETI sends but can't see bit 8 for message separators so I just use the message separator and checksum information in bits 0-7) and 1 stop bit.
I've reached the point where all my unit tests based on the examples on page 7 of the JETI protocol spec here are passing. But none of the messages I'm receiving from the actual hardware are passing the checksum test. From the headers they seem to be a mix of JETI packet types 0, 1 and 2, all 34 bytes long which doesn't seem right (34 is the length of simple text messages but the headers are for ex data and ex text).
There are three main possibilities I can think of:
- My 9600 baud 8/ignore/1 serial parameters don't work and I'm getting garbage which just happens to contain stuff looking like JETI message headers (0x7E, 0xNF, ...)
- The JETI protocol document I'm using is out of date (it has a few typos too, e.g. spelling of length in the checksum example code and the first message type/length breakdown on page 7 has 9 bits which was very confusing)
- When the Spark Switch detects power on the telemetry line it goes into some sort of programming mode to work with Powerbox Terminal and isn't sending JETI at all
To help with (1) can you tell me the serial parameters used by Powerbox Terminal so that I can duplicate them? For (2) can you confirm if that protocol document matches the EX Data/EX Text/Simple Text JETI protocol your code uses and tell me what sort of messages I should expect to see coming through? And for (3) let me know what conditions need to be in place for JETI telemetry to be sent.
Thanks in advance for your help.