Programming example

This example describes a drilling operation along a line pattern using the example of the "SysDrillDeepHole” cycle

#VAR
  ; input parameters for pattern
  V.L.DiffX           = 10   ( Distance of the positions in X )
  V.L.NumPositions    = 4    ( Number of positions in X )
 
  ; input parameters for drilling cycle:
  V.L.SurfacePosition = 0   ( Z position of workpiece surface )
  V.L.RetractionPlane = 20  ( Z position of retraction plane )
  V.L.SafetyClearance = 2   ( relative value of safety clearance in Z )
  V.L.DrillingDepth   = 30   ( Depth )
  V.L.NumberOfFeeds   = 3    ( Number of feeds )
  V.L.MachiningMode   = 2    ( Machining mode )
  V.L.ReturnClearance = 0.5  ( Return clearance for chip breaking/evac.)
#ENDVAR
 
T2 D2                        ( Tool data )
M6                           ( Tool change )
 
G17 G90 G54 S1000 M03 F800   ( technology data )
 
G00 Z100                     ( Go to z start position )
G00 X0 Y0                    ( 1st drilling position )
 
L CYCLE [NAME=SysDrillPatternLine.ecy       \
  ; drill parameter of SysDrillDeepHole.ecy:
  @P1  = V.L.SurfacePosition                \
  @P2  = V.L.RetractionPlane                \
  @P3  = V.L.SafetyClearance                \
  @P4  = V.L.DrillingDepth                  \
  @P11 = V.L.NumberOfFeeds                  \
  @P31 = V.L.MachiningMode                  \
  @P61 = V.L.ReturnClearance                \
 
  ; pattern parameter and ref cycle:
  @P100 = "SysDrillDeepHole"                \
  @P107 = V.L.NumPositions                  \
  @P104 = V.L.DiffX                         \
  ]
 
G00 Z200 M5                  ( Final position, spindle stop )
 
M30