Application Program For Data Reception Using A Combination That Does Not Specify The Start Frame - Mitsubishi Electric MELSEC iQ-R Series User Manual

Serial communication module
Hide thumbs Also See for MELSEC iQ-R Series:
Table of Contents

Advertisement

Application program for data reception using a combination that
does not specify the start frame
The following shows the program example when receiving data using a combination that does not specify the start frame.
Reception program example
Data reception using a user frame set with the following conditions is shown below.
■C24 interface used for communication with target device
CH1 side RS-232 interface of C24
■Parameter settings
For other than the following items, use default values.
Item
Word/byte units designation
Transparent code for receiving
specification
ASCII-BIN conversion designation
Receive end data quantity
Receive end code
User frame use enable/disable
designation
Start frame No. designation
Final frame No. designation
User frame receiving method
designation
Method 1 dedicated receive end data
quantity designation
*1 It indicates the registered contents of the user frame No. specified to the start and final frame No., respectively.
■Registration contents in user frame
Item
Start frame No.
Final frame No.
■Program example
The following shows the example of data reception with a user frame.
Category
Label name
Module label
C24_1
C24_1.stnCH1.bSet_Req_ReceptionRead
C24_1.stnCH1.bSts_ReceptionAbnormalDetection
C24_1.stnCH1.uResult_ReceiveUserFrame_D
15 DATA COMMUNICATIONS USING USER FRAMES
310
15.3 Program for Data Reception with User Frame
Setting
content
Word/byte
Designated
Do not convert
6
No designation
Use
*1
No designation
*1
Designated
Method 0
0H
User frame No.
1st
0H (none)
2nd
0H (none)
3rd
0H (none)
4th
0H (none)
1st
419H
2nd
0H (none)
3rd
0H (none)
4th
0H (none)
Buffer memory address
Remarks
to store registration
value
150 (96H)
The unit is set to "Word" in the example.
288 (120H)
Specify as follows: Additional code: 10H (DLE),Transparent
code: 02H (STX)
289 (121H)
164 (A4H)
165 (A5H)
173 (ADH)
174 to 177 (AEH to B1H)
178 to 181 (B2H to B5H)
8224 to 8227 (2020H to
2023H)
8228 to 8231 (2024H to
2027H
Registered code
3BH, 04H
Description
Target module
CH1 Reception data read request
CH1 Reception abnormal detection
CH1_Receive user frame (nth)
Registered data content
;, E0T
Device
X3
X4
U0\G603

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents