STX Signal Transmitter Installation and Operation ... - Kistler-Morse
STX Signal Transmitter Installation and Operation ... - Kistler-Morse
STX Signal Transmitter Installation and Operation ... - Kistler-Morse
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
Appendix B. Serial Comm<strong>and</strong>s<br />
Checksum Calculation<br />
The one-byte checksum is calculated by adding the Hex values of all ASCII characters between the<br />
start of message character ‘>’ or acknowledge character ‘A’ <strong>and</strong> the checksum character ’ss.’<br />
Overflows from the addition are ignored.<br />
Example:<br />
Request<br />
To request gross engineering units (such as weight) from an <strong>STX</strong>, the comm<strong>and</strong> is:<br />
>aaWssr<br />
If the <strong>STX</strong>’s address is ‘3’, the comm<strong>and</strong> is:<br />
>03Wssr<br />
Calculating the checksum ‘ss’ as the sum of the Hex values of all characters between ‘>’ <strong>and</strong>’ss’:<br />
03W ASCII = 30 Hex + 33 Hex + 57 hex = BA Hex<br />
‘0’ ‘3’ ‘W’<br />
Therefore, the ASCII string transmitted to the <strong>STX</strong> is:<br />
> 0 3 W B A CR<br />
3E 30 33 57 42 41 0D Hex<br />
Response<br />
The response to a request for gross engineering units is:<br />
A±dddddddssr<br />
If the weight is +6384, the response is:<br />
A+0006384ssr<br />
Calculating the checksum ‘ss’ as the sum of the Hex values of all characters between ‘A’ <strong>and</strong> ‘ss’:<br />
+0006384 ASCII = 2B Hex+30 Hex+30 Hex+30 Hex+36 Hex+33 Hex+38 Hex+34 Hex = 190 Hex<br />
‘+’ ‘0’ ‘0’ ‘0’ ‘6’ ‘3’ ‘8’ ‘4’<br />
Ignoring the overflow, the checksum is 90 Hex. Therefore, the ASCII string transmitted back to the<br />
master is:<br />
A + 0 0 0 6 3 8 4 9 0 CR<br />
41 2B 30 30 30 36 33 38 34 39 30 0D Hex<br />
B-3