Omron CS1W-MC221 - 02-2008 Operation Manual page 490

Motion control units
Table of Contents

Advertisement

Executing MC Programs from the Ladder Program
Ladder Programming
Example
In this example procedure, task 1 is executed. The following table shows the
equivalent CIO Area control bits and CIO Area words for tasks 2 to 4.
Task
2
n+5: bit 01
3
n+7: bit 01
4
n+9: bit 01
The following ladder program executes Task 1 in the MC Unit.
Automatic/Manual
Mode Switch
Pause button
n+15 04
Program
Program
start button
Execution Flag
n+15 05
Program Execution
Completed Flag
n+22 02
n+25 02
X-axis
Y-axis
Servo-lock
Servo-lock
ON Flag
ON Flag
R1
n+15 04
n+3 05
Program
Execution Flag
Pause Bit
Execution
condition
Cycle Start
Received
R2
n+15 09
n+3 05
R3
n+3 02
Pause
Program Ex-
Bit
ecution Com-
pleted Flag
Cycle
Start Bit
Note When executing a positioning operation in the MC program, all of the axes
being used must be servo-locked (Servo-lock ON Flags must be turned ON),
so be sure to add a condition like R4 in the programming example above.
Automatic
Program
Mode Bit
number
n+4
n+6
n+8
n+15 02
R4
n+10 14
Automatic
Servo
Error
Mode
-lock
Flag
Flag
ON
Section 8-2
Program
Cycle Start Bit
Number Read
Bit
n+5: bit 07
n+5: bit 02
n+7: bit 07
n+7: bit 02
n+9: bit 07
n+9: bit 02
OUT
n+3
(Automatic/Manual
01
Mode Bit)
DIFU(13)
R1
(Work Bit)
DIFU(13)
R2
(Work Bit)
DIFU(13)
R3
(Work Bit)
OUT
(Work Bit)
R4
Both axes are used
in this example.
n+3
OUT
05
(Pause Bit)
Sets the program
number in word
n+2
OUT
n+3
(Program Number
07
Read Bit)
n+3
OUT
02
(Cycle Start Bit)
463

Advertisement

Table of Contents
loading

This manual is also suitable for:

Cs1w-mc221Cs1w-mc221-v1Cs1w-mc421Cs1w-mc421-v1

Table of Contents