Toshiba S2T UDP/IP Socket Interface, A H3100 fixed, B Result status, A+1 UDP open command H0031

Models: S2T

1 8
Download 8 pages 34.6 Kb
Page 5
Image 5
UDP/IP Socket Interface:

UDP/IP Socket Interface:

To use UDP/IP transmission, it is necessary to create a small program in the S2T. The program will utilize the SEND and RECV instructions. The general procedure is as follows:

1.Execute UDP socket open: The Specified Port number must be different from the Port number for T-PDS connection. If the Port number for T-PDS is 2000, the Port number for UDP socket must be other than 2000 to 2002. It is recommended that 2 UDP sockets be opened. One for data send and one for data receive respectively.

2.Execute UDP send and/or UDP receive to exchange data via Ethernet.

3.UDP socket close.

The instruction information on these functions is shown as follows.

UDP Socket Open: SEND instruction is used. ▬[ A SEND B ]▬.

A: H3100 (fixed)

B: Result status

A+1: UDP open command (H0031)

B+1: Error code

A+2: Socket number (1 to 12)

 

A+3: UDP Port number

 

Sample Program

 

12544 = H3100

49 = H0031 Socket number =1 Port number = 4000

When R0620 is set to ON, the UDP open operation is executed. When the operation is finished R0620 is reset to OFF automatically.

Page 5

Page 5
Image 5
Toshiba S2T UDP/IP Socket Interface, A H3100 fixed, B Result status, A+1 UDP open command H0031, B+1 Error code