Mitsubishi MELSEC L Series User Manual page 43

Cpu module, built-in ethernet function
Hide thumbs Also See for MELSEC L Series:
Table of Contents

Advertisement

(2) Program example for Active open
The following shows a communication flow of an Active open.
SP.SOCOPEN instruction
Send by the SP.SOCSND
instruction, or receive by the
S.SOCRCVS instruction.
(a) Parameter setting
The following parameters are set for the sample program.
Project window
[Open Setting]
Item
Protocol
Open System
TCP Connection
Host Station Port No.
Destination IP Address
Destination Port No.
Start
Specify the port number of the external device waiting for
TCP connection and open a connection by Active open.
Open processing:
YES (Completed, or disconnected by the external device.)
Was data transfer
completed?
NO
Close processing:
SP.SOCCLOSE instruction
SP.SOCRCV or
[Parameter]
[PLC Parameter]
TCP
Socket Communication
Active
1000
(Setting range: 0001
H
H
192.168.3.40 (Setting range: 0.0.0.1 to 223.255.255.254)
1000
(Setting range: 0001
H
H
CHAPTER 6 SOCKET COMMUNICATION FUNCTION
End
[Built-in Ethernet Port Setting]
Setting
to 1387
, 1392
to FFFE
)
H
H
H
to FFFE
)
H
6
41

Advertisement

Table of Contents
loading

Table of Contents