![background image](http://html1.mh-extra.com/html/omron/cs1w-213-rev-02-2008/cs1w-213-rev-02-2008_operation-manual_742355159.webp)
134
Writing Data with IOWR
Section 5-4
Example: Sending 200 Words of Speed and Position Data and Starting
Operation
The following ladder program can be used to transfer 100 words (50 items) of
speed data and 100 words (50 items) of position data using the IOWR instruc-
tion and start operation.
In the above ladder diagram, when the first IOWR instruction is executed, the
Equals Flag turns ON and, at the same time, the data is transferred to the
PCU. At the PCU, this data is first stored in the receive buffer. After this, the
next IOWR instruction is executed. Because the data in the receive buffer has
not been processed (i.e., to check that the data items are within the respective
ranges and write the data to the data area), the Equals Flag, which is the
completion flag for the IOWR instruction, does not turn ON. Therefore, the
IOWR
#112C
D00500
#00640002
R1
R2
R3
=
Set the address (112C Hex)
for the X-axis speed.
Set the beginning word of the
transfer source where the
speed data is set.
DIFU R1 (work bit)
Set the destination unit number
(2) and the number of transfer
words (100 = 64 Hex).
OUT R3 (work bit)
OUT R2 (work bit)
IOWR
#11F4
D00600
#00640002
R3
R4
R5
=
Set the address (11F4 Hex)
for the X-axis position.
Set the beginning word of the
transfer source where the
position data is set.
OUT R5 (work bit)
OUT R4 (work bit)
START
Set the destination unit number
(2) and the number of transfer
words (100 = 64 Hex).
DIFU
R1
Write switch
MOV
#0000
D00216
R5
202000
202001
Sequence Number Enable
Sets #0 for the
sequence number.
Unit: NC113
Unit number: 2
Beginning word of operating
data area: D00200
Busy Flag
200213
202001
START Bit
Содержание CS1W-213 - REV 02-2008
Страница 1: ...Position Control Units Cat No W376 E1 06 SYSMAC CS1W NC113 213 413 133 233 433 OPERATION MANUAL ...
Страница 2: ...CS1W NC113 213 413 133 233 433 Position Control Units Operation Manual Revised February 2008 ...
Страница 3: ...iv ...
Страница 13: ...xiv ...
Страница 15: ...xvi ...
Страница 19: ...xx ...
Страница 43: ...18 Basic Operational Flow Section 2 1 ...
Страница 87: ...62 Servo Relay Unit Section 3 7 ...
Страница 199: ...174 Z phase Margin Section 6 8 ...
Страница 217: ...192 Sample Program Section 7 7 ...
Страница 285: ...260 Easy Backup Function Ver 2 0 or later Section 9 11 ...
Страница 377: ...352 Common Parameter Area Appendix C ...
Страница 395: ...370 Parameter Coding Sheets Appendix F ...