Omron CS1W-MCH71 Operation Manual page 665

Sysmac cs/cj-series
Hide thumbs Also See for CS1W-MCH71:
Table of Contents

Advertisement

Others
Example 2
620
ENDIF;
IF #SL0244>20000; Torque in Axis 2
#MB00001 = 1;
ELSE;
#MB00001 = 0;
ENDIF;
IF #SL0274>20000; Torque in Axis 3
#MB00002 = 1;
ELSE;
#MB00002 = 0;
ENDIF;
;If any of the drives has a torque bigger than 200% we set a bit
;in an output variable (for PLC control)
IF #MW0000>0;
#OB0BA20 = 1;
ENDIF;
WED;
JOINT;
;Pick and place sequence:
; - Go to 'pick piece' position
MOVEL[J01]500 [J02]300 F200;
; - Pick the piece
MOVE [J03]50;
WAIT #IB0B001 = = 1; Bit for 'Down operation completed'
MOVE [J03]0;
WAIT #IB0B002 = = 1; Bit for 'Pick/place operation completed
; - Go to 'place piece' position
MOVEL[J01]0 [J02]0 F100;
; - Place the piece
MOVE [J03]50;
WAIT #IB0B001 = = 1;
MOVE [J03]0;
WAIT #IB0B002 = = 1;
;Flag to indicate that the cycle has finished
#DB00000 = 1;
JWAIT;
ENDIF;
WEND;
END;
This example is the motion program for a 'Bag making' machine. The machine
consist in a feeding roll that feeds the bag plastic film that is soldered and cut.
The program receives two data from the MMI (via the PC backplane): the feed
length and the speed in bags/minute. With this data the program calculates, in
a sub-program, the suitable profile (acceleration and deceleration ramps and
maximum speed). The machine has two operation modes: without mark, that
is, making a fixed movement; or with mark, that is, correcting the movement
depending on the position of a printed mark. The cutter is activated by the
program via a flag (bit).
The program for a real machine will need some modification as windowing of
the registration mark, undetected marks alarm counter, etc.
PROG P005 Q00000001;Bag making
;--------------------------------------------------------------------------------
;Bag making with mark needs to configure a registration input in the
servodrive
;it is necessary to set P50108 (eg = xxxxxx03h) and Pn511 (eg =
Section 10-3

Advertisement

Table of Contents

Troubleshooting

loading

This manual is also suitable for:

Cj1w-mch71

Table of Contents