Program Example - Omron CS1W-SLK11-21 - 06-2004 Manual

Sysmac link units
Table of Contents

Advertisement

PLC Network Instructions
6-2-8

Program Example

0000
A202
1200
00
07
02H
1200
01
1200
00
1200
A202
00
07
1200
A219
00
07
0000
A219
1200
01
07
00
1200
03
1200
02
1200
A202
02
07
1200
A219
02
07
1200
1200
A219
02
03
07
104
(011)
KEEP
120000
(021)
@MOV #000A D00000
(021)
@MOV #0002 D00001
(021)
@MOV #0400 D00002
(021)
@MOV #0705 D00003
(021)
@MOV #0064 D00004
(070)
@XFER &0010
0000 D00010
(090)
@SEND D00010
D00020 D00000
(013)
DIFU
120001
1210
00
(011)
KEEP 120002
(021)
@MOV
#0010 D00005
(021)
@MOV
#0003 D00006
(021)
@MOV
#3000 D00007
(021)
@MOV
#070F D00008
(021)
@MOV
#0000 D00009
(98)
@RECV
A100
2000
D00005
(013)
DIFU
120003
1210
01
(070)
@XFER &0016
2000
D00040
The SEND(90) program section will run when
CIO 000000 is ON, provided that the Enabled Flag for
port 7 is ON and the RECV(98) instruction has not been
executed.
CIO 120000 is ON while the SEND(90) instruction is
being executed, and it goes OFF when the execution of
the instruction has been completed.
The 10-word data starting from D00010 on the local PLC
is sent to D00020 and following words on the PLC with a
unit address of 0, node address of 4, and network
address of 2.
Word
Content
Meaning
D00000 00
0A Number of words: 10
D00001 00
02 Destination network address: 2
D00002 04
00 Destination node address: 4
Destination unit address: 0
05 Communications port No.: 7
D00003 07
Number of retries: 5
D00004 00
64 Response monitor time: 10 s
Storing the Send Data
The 10-word data starting from 0000 is stored in
D00010 and following words.
Transmission error display
The RECV(98) program will run when CIO 000001 is
ON, provided that the Enabled Flag for port 7 is ON and
the SEND(90) instruction has not been executed.
CIO 120002 is ON while the RECV(98) instruction is
being executed, and it goes OFF when the execution of
the instruction has been completed.
The 16-word data starting from A100 on the PLC with a
unit address of 0, node address of 48, network address
of 3 is stored at CIO 2000 and following words a the
local PLC.
Word
Content
Meaning
D00005 00
10 Number of words: 16
D00006 00
03 Destination network address: 3
D00007 30
00 Destination node address: 48
Destination Unit address: 0
D00008 07
0F Communications port No.: 7
Number of retries: 15
D00009 00
00 Response monitor time: Default
Reception error display
Reception data processing
When the data is received without an error, the 16-word
data received at CIO 2000 and following words is
stored in D00040 and following words on the same PLC.
Section 6-2

Advertisement

Table of Contents

Troubleshooting

loading

This manual is also suitable for:

Sysmac cs1w-slk11Sysmac cs1w-slk21

Table of Contents