App - 8 App - 8
MELSEC-F
APPENDIX
(4) Program on the external device side
The program example of the external device shown below accesses the FX
3U
of
the station in which the Ethernet module is installed.
When this program is executed, the contents of the following communication
messages are displayed in sequence:
1) Batch write command message in word units
2) Batch write response message in word units
3) Batch read command message in word units
4) Batch read response message in word units
REMARK
(1) The following explains an outline of the compiling procedure for a program
created using Microsoft
®
Corporation Visual C
++
.NET
1) Start Visual C
++
.
2) Prepare for program creation.
Select “New Project” from the project tab, select “Win32 console project”,
and create an empty project with the name “ENETSAMP”.
3) Add ENETSAMP.C to the project and create a program.
(See the program example on the next page.)
4) Compile the created file from the compile screen of the build menu.
5) From the project menu property setting screen, add WSOCK32.LIB to the
linker addition dependency files.
6) Create an executable file (ENETSAMP.EXE) on the build screen of the
build menu.
7) End Visual C
++
.NET.
8) Execute ENETSAMP.EXE.
(2) Outline of the procedure for calling the socket routine
socket()
bind()
(Bind)
Active open
UDP
listen()
connect()
accept()
send()/recv()
sendto()/recvfrom()
shutdown()
closesocket
(Close)
Start
Complete
(Create socket)
(Open)
(Communicate)
(Disable sending/receiving)
Passive open
Содержание FX3U-ENET
Страница 1: ...USER S MANUAL FX3U ENET ...
Страница 2: ......
Страница 159: ...8 6 8 6 MELSEC F 8 COMMUNICATION USING MC PROTOCOL MEMO ...
Страница 295: ...App 25 App 25 MELSEC F APPENDIX MEMO ...
Страница 297: ......