Programming; Serial Data Communication - Mitsubishi MELSEC iQ-F FX5 User Manual

Hide thumbs Also See for MELSEC iQ-F FX5:
Table of Contents

Advertisement

6.7

Programming

This section explains how to create programs for non-protocol communication using RS2 instruction and how such programs
operate.
For details on related devices, refer to Page 179 Related Devices.
For communication settings, refer to Page 159 Communication Settings.

Serial data communication

This section explains the function, operation and programming method of the RS2 instruction.
For details on the expression and executable format of the RS2 instruction, refer to the MELSEC iQ-F FX5 Programming
Manual (Instructions, Standard Functions/Function Blocks).
RS2
This instruction sends and receives data in non-protocol communication using the communication board or communication
adapter connected to the CPU module or using the built-in RS-485 port to the CPU module.
Ladder
(s)
(n1)
Setting data
■Content, range, data types
Operand
Description
(s)
Head device storing send data
(n1)
Number of send data
(d)
Head device storing receive data
(n2)
Amount of received data
(n3)
Communication CH
■Applicable devices
Operand
Bit
X, Y, M, L, SM,
F, B, SB, S
(s)
(n1)
(d)
(n2)
(n3)
*1 T,ST and C cannot be used.
Processing details
This instruction sends and receives data via non-protocol communication by way of built-in RS-485 port, communication
board or communication adapter. This instruction specifies the head device storing the sent data from the CPU module,
amount of data, head device storing the received data and the maximum allowable amount of received data.
6 NON-PROTOCOL COMMUNICATION
162
6.7 Programming
ST
ENO:=RS2(EN,s,n1,n2,n3,d);
(d)
(n2) (n3)
Word
T, ST, C, D, W,
U\G
SD, SW, R
*1
*1
Range
0 to 4096
0 to 4096
K1 to 4
Double word Indirect
specification
Z
LC
LZ
FBD/LD
EN
s
n1
n2
n3
Data type
Data type (label)
16-bit signed binary /
ANY16
character string
16-bit unsigned binary
ANY16_U
16-bit signed binary /
ANY16
character string
16-bit unsigned binary
ANY16_U
16-bit unsigned binary
ANY16_U
Constant
K, H
E
$
ENO
d
Others

Advertisement

Table of Contents
loading

Table of Contents