Programming example
Programing Example

Pick & place
The example below contains a program for the case that all workpieces are picked at the same position on the workpiece and placed at the same location in the machine coordinate system. An endless loop is programmed for this reason and the CNC waits again for the next workpiece immediately after placing a workpiece. The linear conveyor is controlled by the CNC (N030) and it is recognisable that a delta robot is used because kinematic 37 is selected at the start.
%pick_and_place
N010 #KIN ID[37]
N020 G0 G90 X34.9485 Y-18.0290 Z34.0535
N020 #TRAFO ON
(- Start conveyor)
N030 S1[MC_MoveVelocity Velocity=300000 (500000=30m/min) Acceleration=2000 Deceleration=2000 Jerk=750000 Direction=1]
N040 $WHILE [TRUE]
; Waiting position
N050 G01 X-100 Y0 Z-700 F350000
(- Request spindle measured value-)
N060 S1 [MC_TouchProbe Channel=1]
(- Synchronise with the current workpiece -)
N070 #SYNC IN [CONVEYOR=S1, CONV_VEL=18000 FEED_CONT=0]
(- Grip the workpiece -)
N075 G01 X-50 Y0 Z-700 F350000
N080 G01 X-50 Y0 Z-800 F350000
N090 G01 X-50 Y0 Z-750 F350000
(- Desynchronise and place the workpiece -)
N100 #SYNC OUT [FEED_CONT=5]
(- Move to place location -)
N110 X[INDP_SYN G1 G90 POS300 FEED350000 INTERRUPTIBLE] Y[INDP_SYN G1 G90 POS500 FEED350000 INTERRUPTIBLE] Z[INDP_SYN G1 G90 POS-750 FEED350000 INTERRUPTIBLE]
(- Place -)
N120 G01 Z-790 F350000
N130 G01 Z-800 F20000
N140 G01 Z-790 F350000
N150 $ENDWHILE
(-Program ended-)
N160 M30