7 SOCKET COMMUNICATION FUNCTION INSTRUCTION
7.5 Changing Destination
267
7
Precautions
• Use the Built-in Ethernet port QCPU of which the function version is B or later and the first five digits of the serial number
are '11012' or higher.
• Use the LCPU other than L02SCPU and L02SCPU-P.
Program example
• The following program changes the destination (destination IP address and port number) of the connection number 1 which
is being open.
[Structured ladder/FBD]
[ST]
IF((LDP( TRUE, Var_Flag_Inst )) &(SD1282.0=TRUE))THEN
MOVP( TRUE, H55DE, Var_ControlData[2] );
MOVP( TRUE, H0A61, Var_ControlData[3] ); (* Sets destination IP address to 10.97.85.222 *)
MOVP(TRUE, H2001, Var_ControlData[4]); (* Sets destination port number to 8193 *)
SP_SOCCSET( TRUE, "U0", 1, Var_ControlData ); (* Changes the setting of the connection number 1 *)
END_IF;
Sets destination
IP address
to 10.97.85.222
Sets destination
port number to 8193
Changes the setting
of the connection
number 1
Содержание MELSEC System Q
Страница 1: ...MELSEC Q L Structured Programming Manual Special Instructions ...
Страница 2: ......
Страница 307: ...10 SFC CONTROL INSTRUCTION 10 2 SFC Transition Condition Comment Read 305 10 MEMO ...
Страница 309: ...I 307 MEMO ...
Страница 315: ......