Xilica XD Series User Manual

Page 3

background image


The Checksum is calculated from <01> to the character before the checksum, which should be <1F>.

The formula used is:

byte i, nChksum;




(i = 0, nChecksum = 0; i++) nChecksum += nTx[i]; // Add all hex number before the checksum


nTx is the buffer holding all transmit data

nChecksum %= 0x60;

// Modulo of <60> (Remainder when divided by <60>)

nChecksum += 0x20;

// Add <20> to become readable ascii

So <CHECKSUM> is the value of nChecksum.


The process byte is always <1F>. It tells the device to process the information (Command, Device, I/O, Channel, Aux

commands and values) before it.

This manual is related to the following products: