User`s manual

324
13.4.1 Example of data reception
The following shows an example of data reception:
(1) Reception using the receive complete code
Complete code: 9H (the code after ASCII-BIN conversion)
When ASCII-BIN conversion is enabled, the codes of receivable data and the codes of receive data that is stored in the
reception area of the buffer memory are as follows:
If data codes other than 30H to 39H and 41H to 46H are received for an arbitrary data section, an error occurs after ASCII-
BIN conversion processing by the Q series C24.
To perform ASCII-BIN conversion, the complete code after conversion should be used.
Item Receivable codes Codes stored in the reception area
Arbitrary data section (including complete code
section)
30H to 39H, 41H to 46H 0H to 9H, AH to FH
30H 31H 32H 33H 34H 35H 41H 43H 44H 45H39H42H
0123 BA45 DC9E
X83
M0
M1
ON
ON
600H
601H
602H
603H
00H , 03H
23H , 01H
ABH , 45H
E9H , CDH
D10
D11
D12
00H , 03H
23H , 01H
ABH , 45H
E9H , CDH
D2
*
INPUT
Programmable
controller CPU
Completion device
External device side
Programmable
controller CPU side
Reception data read
request
Head data
Status display device
at completion
One scan
Abnormal completion
Normal completion
Number of bytes after
ASCII-BIN conversion:
((6)/2=3) when word
units are used,
(6) when byte
units are used
The diagram below is for when
word units are used.
Buffer memory Sequence program
device memory
Store data
received count
Data corresponding
to complete code
2)
3)
Set to even byte
Two bytes of receive data is read to
the programmable controller CPU as
one-byte data.
Send data from the external device so
that the converted complete code data
is arranged with data having an even
byte number.
Sets CH1 to the reception
channel
Sets the normal completion flag
Sets the abnormal completion flag
Executes reception
Reception data read request
Sets the allowable number of
receive data to 6