Kaiyi — 6.19.2 Explanation of Communication Instructions

Chapter 6 Applied Instruction Example: Reading the data from the two registers in the drive at address 16#01 The initial register address is 16#2102. The RTU mode (SM210/SM212 is ON): Communication address: 16#00: Broadcasting to all drives 16#01: Broadcasting to the drive at address 01 16#0F: Broadcasting to the drive at address 15 16#10: Broadcasting to the drive at address 16 … 16#FE: Broadcasting to the drive at address 247 Function code: 16#03: Reading the data from several registers 16#06: Writing the one-bit data into the register 16#10: Writing the data into several registers Data: The data which users send CRC check code:

The operations are performed on the communication address and the data. The operation rule is as follows. Step 1: Suppose the data in the 16-bit register (the register in which the CRC check code is stored) is 16#FFFF. Step 2: The logical operator XOR takes the first 8-bit message and the low 8-bit data in the 6-388 Inquiry message: Response message:

STX ‘:’ STX ‘:’ ‘0’ ‘0’ Address Address ‘1’ ‘1’ ‘0’ ‘0’ Function Function ‘3’ ‘3’ ‘2’ Number of data ‘0’ ‘1’ (counted by the byte) ‘4’ Initial register address ‘0’ ‘1’ Contents of the register ‘2’ ‘7’ at address ‘0’ ‘7’ 16#2102 Number of data ‘0’ ‘0’ (counted by the word) ‘0’ ‘0’ Contents of the register ‘2’ ‘0’ at address ‘D’ ‘0’ LRC check code 16#2103 ‘7’ ‘0’ CR ‘7’ END LRC check code LF ‘1’ CR END LF Start Please refer to the explanation below. Address Communication address: 8-bit binary address Function Function code: 8-bit binary function code DATA (n-1) Data: n×8-bit data ……. DATA 0 CRC CHK Low CRC check code: The 16-bit check code is composed of two 8-bit codes.

CRC CHK High END Please refer to the explanation below.