; Universal helical programme ; ; %x1 = Circle centre X ; %y1 = Circle centre Y ; %z = depth moved in Z ; %h = diameter of move CUTTER centre!!!!!!!!! allow for radius ; %cut step down in Z each circular path %x1 = 275.10 %y1 = -114.60 %z = -7.0 %h = 50. %cut = 0.5 F1000. S600. T10 %hr = %h/2 %depth = (0 - %z) %turns = (%depth / %cut) G61 ; switch to non CC mode G40 G80 ; sets no circular offsets no cycles active G90 ; sets in absolute mode G49 ; clears any length offsets G21 ; declares metric programme G0 Z0.0 M5 ; safety line should not move if machine set up properly G0 X+0.0 Y-0.0 ; safety line should not move if machine set up properly G43 H10 M6 ; use tool length offset & prompt for tool change M07 ; coolant on M3 ; spindle on G00 X%x1 Y%y1 ; move to centre G00 Z20.0 ; rapid to 20mm above surface G00 Z2.0 ; rapid to 2mm above surface G01 Z0.0 ; feed to surface N14 G15 I%hr K%cut L%turns ; make helical moves Z20.0 ; rapid to 20mm above surface M09 ; coolant off M05 ; spindle off G49 ; length offsets cleared G00 Z0.0 ; rapid to Z zero G00 X0.0 Y0.0 ; rapid to X Y zero M30 ; end of programme