LG MASTER-K 120S Series User Manual page 215

Programmable logic controller
Table of Contents

Advertisement

Chapter 8 Communication Functions
(4) Response Format (NAK response)
Format name
Header
Frame (Example)
NAK
ASCII value
H15
Item
BCC
Error code
(5) Example
This example supposes that registered device No. 1 of station No. 1 is read. and BCC value is checked. And it is supposed
that device M000 is registered and the number of blocks is 1.
① Computer request Format (PC → MASTER-K120S Main Unit)
Format name
Frame (Example)
ASCII value
② For ACK response after execution of command (PC ← MASTER-K120S Main Unit)
Format name
Header
Frame (Example)
ACK
ASCII value
H06
③ For NAK response after execution of command (PC ← MASTER-K120S Main Unit)
Format name
Header
Frame (Example)
ASCII value
Station No.
Command
H10
Y(y)
H3130
H59(79)
When command is lowercase(y), only one lower byte of the value resulted by adding 1 Byte
each to ASCII values from NAK to ETX is converted into ASCII and added to BCC, and
sent.
Hex and 2 bytes (ASCII code, 4 bytes) indicate error type. For the details, see 8.1.8 Error
codes.
Header
Station No.
ENQ
H01
H05
H3031
Station No.
Command
H01
y
H3031
H79
Station No.
Command
NAK
H01
H15
H3031
H79
Registration
No.
H09
H3039
H31313332
Explanation
Registration No.
Command
y
H79
H3031
Registration
Number of Blocks
No.
H01
H01
H3031
H3031
Registration No.
y
H01
H3031
8-25
Error code
Tail
(Hex 2Byte)
H1132
ETX
H03
Tail
H01
EOT
H04
Number of
Data
Tail
data
H04
H23422339
ETX
H3233343232
H3034
H03
333339
Error code
Tail
Error code (2)
ETX
Error code (4)
H03
Frame check
BCC
Frame check
BCC
Frame
check
BCC
Frame check
BCC

Advertisement

Table of Contents
loading

Table of Contents