Omron CJ1W-ETN21 operation manual System Configuration, Close Request during Receive Request

Models: CJ1W-ETN21

1 242
Download 242 pages 30.9 Kb
Page 165
Image 165

Using Socket Services with CMND(490)

Section 6-8

CLOSE REQUEST during RECEIVE REQUEST

RECEIVE REQUEST

CLOSE REQUEST

command received

command received

Port Enabled Flag

1

0

CMND(490) (RECEIVE REQUEST)

 

response command

 

CMND(490) (CLOSE REQUEST)

 

response command

 

Receive Flag

1

0

Close Flag

1

0

Opening Flag

1

0

Results storage area for

RECEIVE REQUEST

Results storage area for

CLOSE REQUEST

 

Running

 

Running

 

Normal response code

Normal response code

Store error response code

Store normal response code

Note The timing shown in the above diagram occurs if a CLOSE REQUEST com- mand is executed during SEND REQUEST command execution. The timing shown in the diagram also applies if a CLOSE REQUEST command is exe- cuted during OPEN REQUEST command execution, with the exception of the status of the Opening Flag.

6-8-8 TCP/IP Communications Programming Example

The following programming example illustrates transferring 100 bytes of data between an Ethernet Unit and a host computer using TCP/IP communications.

System Configuration

The system configuration for the program example and the Ethernet Unit system setup are shown below. To establish a TCP connection, the Ethernet Unit is passively opened and the host computer actively opened.

Host computer

Ethernet Unit

PLC

IP address:

196.36.32.55

IP address:

196.36.32.101

Port number:

4096

Port number:

4096

 

 

FINS network address:

01 Hex

 

 

Node address:

01 Hex

 

 

Unit number:

10 Hex

141

Page 165
Image 165
Omron CJ1W-ETN21 operation manual System Configuration, Close Request during Receive Request