Hitachi SJ Series User Manual page 500

Hide thumbs Also See for SJ Series:
Table of Contents

Advertisement

Chapter 14
14.3.5
Error check
• To check errors in Modbus-RTU, use CRC (Cyclic
Redundancy Check).
• To generate a CRC code, use the generating polynomial
16
15
2
for CRC-16 (X
+X
+X
+1).
Example of procedure for calculating CRC-16.
CRC-16 calculation
CRC*1=FFFFh
Target data
Calculation of the
Swapping high bytes and
low bytes in CRC*1.
Finished.
Yes
target data is
finished.
• CRC codes are16 bits data generated for a block with
arbitrary data length in 8-bit unit.
CRC*1= CRC*1 XOR target data
Shift by 8 bits
There is a remaining bit.
CRC*1= Shift CRC*1 by 1 bit to the
0
A bit shifted out
1
CRC*1= CRC*1 XOR A001h
Shift as much as 1 byte for the target data.
14-9
RS485 Communication
CRC*1
Hi
Lo
CRC register (2 bytes)
Finished

Advertisement

Table of Contents
loading

Table of Contents