1

I'm trying to decode the protocol to control the PA amp t.amp Quadro 500 DSP (also branded as FiveO AR4). The serial interface is provided by an PL2303 interface, Baud 57600 8N1.

To set volume on channel 1 I can increase from 0h00 to eg 0h3F using those commands:

0120 0300 15 00000000000200 00 000000000000 75 40
0120 0300 15 00000000000200 01 000000000000 74 40
0120 0300 15 00000000000200 02 000000000000 77 40
0120 0300 15 00000000000200 03 000000000000 76 40
0120 0300 15 00000000000200 2D 000000000000 58 40
0120 0300 15 00000000000200 2E 000000000000 5B 40
0120 0300 15 00000000000200 3F 000000000000 4A 40

Keepalive command sent every few second:

0120 0300 17 00000000000E00 00 0000000000000000 7B 40

The first 4 bytes are start bytes, the last is terminating the command and 0h15 is the command length. 0h2D-3F is the gain.

What I didn't get is to calculate the checksum-byte just before the end byte.

Do you have any idea how to calculate it properly?

kind regards

1

using dotPeek finally I found the (very simple) solution:

int crcIndex = numArray.length - 2;
buffer[crcIndex];

for (int index = 1; index < buffer.length; ++index) {
    if (index != crcIndex)
    buffer[crcIndex] ^= buffer[index];
}

Basically its a XOR walked thru every byte, skipping the CRC byte itself but including the last byte.

regards

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.