Chapter 8 Communication Functions

3)Address area

(1)Setting range is available from 1 to 247, but MASTER-K120S supports from 0 to 31.

(2)Address 0 is used for broadcast address. Broadcast address is all slave device recognize and respond to like the self- address, which can't be supported by MASTER-K120S.

4)Function code area

(1)MASTER-K120S supports only 01, 02, 03, 04, 05, 06, 15, and 16 among Modicon products' function codes.

(2)If the response format is confirm+(ACK), it uses the same function code.

(3)If the response format is confirm-(NCK), it returns as it sets the 8th bit of function code as 1.

Ex) If function code is 03, (we write here only function code part. Because only function codes are different.)

[Request]

0000 0011 (H03)

[Confirm+]

0000 0011 (H03)

[Confirm-]

 

000 0011 (H83)

1

It returns as it sets the 8th bit of function code of request frame.

5)Data area

(1)It sends data, using ASCII data(ASCII mode) or hex (RTU mode).

(2)Data is changed according to each function code.

(3)Response frame uses data area as response data or error code.

6)LRC Check/CRC Check area

(1)LRC (Longitudinal Redundancy Check) : It works in ASCII mode. It takes 2’ complement from sum of frame except header or tail to change into ASCII code,

(2)CRC (Cyclical Redundancy Check): It works in RTU mode. It uses 2-byte CRC check rules.

REMARK

1)All numerical data can use hexadecimal, decimal, and binary type. If we convert decimal 7 and 10 into each type: Hexadecimal : H07, H0A or 16#07, 16#0A

Decimal : 7, 10

Binary : 2#0111, 2#1010

8-58

Page 248
Image 248
LG Electronics 120S user manual Address area, Function code area, Data area, LRC Check/CRC Check area