CHAPTER 6 USING THE COMMUNICATIONS FUNCTION
E5CK
6–6
Ă• End code
Sets the communication results. For details on the types and meanings
of end codes, see 6.5 How to Read Communications Error Information
(page 6Ć12).
Ă• FCS (Frame Check Sequence)
Set the frame check results from the start character to the data area. For
details on the frame check, see 6.6 Program Example (page 6Ć18).
Ă• *" CR (Carriage Return) code"
Indicates the end (terminator) of the command or response block.
Conversion to ASCII code at each digit of the calculation result and setting to FCS
Calculate the exclusive OR from the start character to the data section. The followĆ
ing describes an example of how to calculate the FCS for @001000000".
How to Calculate
FCS
(1) Convert the ASCII codes of each character to Hexadecimal 40H, 30H, ...,
30H".
(2) Calculate the exclusive OR of all characters.
(3) Convert to ASCII code. (³ 4B")
(4) Set the result as FCS.
ASCII ³ Hex
ASCII @ 0 01000000
Hex 40H 30H 30H 31H 30H 30H 30H 30H 30H 30H
Completed frame (with appended terminator)
Exclusive OR
ASCII @ 0 0100000071
Hex 40H 30H 30H 31H 30H 30H 30H 30H 30H 30H 37H 31H
ASCII @ 0 0100000071*CR
Hex 40H 30H 30H 31H 30H 30H 30H 30H 30H 30H 37H 31H 2AH 0DH
FCS
FCS Terminator
40H30H30H31H30H30H30H30H30H30H=71H