Description of commands and responses, 0 0 1 5 c n t, Kv -300 – KEYENCE Visual KV Series User Manual
Page 301

7.6 Display Interface Mode Programming
KV-300 Series Only
KV
-300
KV-10/80
Chapter 7 KV-L2 Serial Interface Module
1-277
1
7
3. Command data
Set the relay no., data memory address, and instruction word using ASCII char-
acters. For reference, the relay no. "0015" is converted to "30 30 31 35" in ASCII
code values, and the instruction word "CNT_" to read the set value of counter/
timer (R#) is converted to "43 4E 54 20" in ASCII codes .
Command code(ASCII characters)
ASCII code conversion for FCS calculations
4. FCS (frame check sequence)
The FCS (frame check sequence) is a method for detecting a communication
error. It calculates the exclusive OR within the following range. The calculated 8-
bit data is converted to a 2-ASCII character.
Description of commands and responses
This section describes the format of commands and responses. In the following
figure, "n" represents one ASCII character (1 byte). The characters stand for two
types of values: One is a decimal value representing a numeric value between 0 and
9 for station no., channel no., address no., and timer/ counter values: the other is a
hexadecimal value representing a numeric value between $0 and $F for binary data
bit information of I/O or Data Memory.
Read I/O relay/internal utility relay (RR)
This command reads the I/O relays/internal utility relays starting from the specified
channel no. within the specified range.
■ Command format
■ Response format (When the command is executed normally, the response
includes the end code "00".)
Read temporary data memory address/analog timer (RH)
This command reads the current value of the temporary data memory address/
analog timer starting from the specified no. within the specified range.
@
❋
C
R
FCS
Station no.
Header
code
Command/response
data
FCS calculation range
Station no.
nn
@
RR
FCS
❋
C
R
End code
nn
Data
nnnn
Data
nnnn
Header code
Terminator
Data of read start ch.
+1(in hexadecimal)
Data of read start ch.
(in hexadecimal)
@
FCS
RR
❋
C
R
Station no.
nn
Read start
ch.
nnnn
Number of
channels to
read: nnnn
Header
code
00 to 15
(in decimal)
Terminator
0001 to 0180
(in decimal)
0000 to 0179
(in decimal)
0 0 1 5
C N T
4EH
30H
31H
30H
35H
20H
43H
54H
KVHKA Chap 07_5to10.p65
08.3.11, 11:18 AM
277