===== case 0000 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=20 0 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: profile needs at least 2 points
===== case 0001 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile= prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: profile needs at least 2 points
===== case 0002 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=20 0;20 5 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: point 2: Z must not increase going away from the face (Z 0.000 then 5.000). G71 needs a monotonic Z; a reversal is a re-entrant undercut, not supported.
===== case 0003 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=20 0;20 0 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: point 2: duplicate point (Z 0.000 dia 20.000)
===== case 0004 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=20 0 R2;20 -25;40 -25 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: the first point cannot carry an R/C corner
===== case 0005 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=20 0;20 -25;40 -25 R2 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: the last point cannot carry an R/C corner
===== case 0006 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=-5 0;20 -25 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: profile line 1: negative diameter -5.000
===== case 0007 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=20 0;20 -25 Q3;40 -25 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: profile line 2: expected R<rad> or C<cham>, got 'Q3'
===== case 0008 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=20 0;20 -25 R;40 -25 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: profile line 2: R needs a value
===== case 0009 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=20 0;20 -25 R0;40 -25 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: profile line 2: R must be > 0
===== case 0010 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=abc 0;20 -25 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: profile line 1: X and Z must be numbers, got 'abc 0'
===== case 0011 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=20;20 -25 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: profile line 1: need at least 'X Z', got '20'
===== case 0012 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=20 0;20 -25 R30;40 -25;40 -60 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: point 3: R/C of 30.000 does not fit the adjacent segment (25.000 available)
===== case 0013 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=20 0;40 0 R2;20 0 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
!! ValueError: point 3: cannot blend a full reversal
===== case 0014 | clear_z=5.0 clearance=2.0 coolant_type=1 do_finish=1 doc=2.0 feed_finish=0.12 feed_first=0.0 feed_rough=0.3 finish_nose_r=0.4 finish_tool=2 finish_x=0.4 finish_z=0.1 max_rpm=600.0 nose_r=0.8 profile=20 0;20 -25 R3;20 -50 prog=1000 retract=1.0 rpm=600.0 sep_finish_tool=0 spindle_mode=0 stock_dia=52.0 stock_z=1.0 surface_speed=180.0 tool=1 =====
(Lathe OD profile - LONGHAND expansion of G71/G70 - same toolpath)
(Set work zero at the finished face, on the spindle centreline)
(self-contained: no subroutine, no canned cycle)
(Stock dia 52.000  face Z 1.000  ->  profile dia 20.000  Z -50.000)
(Tool T0101   wcs G54  coolant flood)
(rough + finish - rough DOC 2.000  retract 1.000  finish allowance X 0.400 rad / Z 0.100)
(CSS 180 m/min  max 600 rpm  feed rough 0.3000 / finish 0.1200 mm-rev)
(=== conversational block - do not edit; lets the panel reload this file ===)
(CONV1 cycle=od_profile)
(CONV1 prog=1000 tool=1 stock_dia=52 stock_z=1 doc=2 finish_x=0.4)
(CONV1 finish_z=0.1 nose_r=0.8 retract=1 surface_speed=180 max_rpm=600 spindle_mode=0)
(CONV1 rpm=600 feed_rough=0.3 feed_first=0 feed_finish=0.12 do_finish=1 sep_finish_tool=0)
(CONV1 finish_tool=2 finish_nose_r=0.4 clearance=2 clear_z=5 coolant_type=1)
(CONV1 P 20 0)
(CONV1 P 20 -25 R3)
(CONV1 P 20 -50)
(CONV1 END)
G18 G21 G7 G90 G95 G40
G64 P0.02
G54
G30
T0101
G96 S180 D600 M3
M8
G0 X52.0000 Z1.0000
G1 X52.0000 Z-50.8000 F0.3000
G0 X54.0000 Z-49.8000
G0 X54.0000 Z0.0000
G0 X52.0000 Z1.0000
G0 X48.0000 Z0.8974
G1 X48.0000 Z-50.8000
G0 X50.0000 Z-49.8000
G0 X50.0000 Z-0.1026
G0 X48.0000 Z0.8974
G0 X44.0000 Z0.7949
G1 X44.0000 Z-50.8000
G0 X46.0000 Z-49.8000
G0 X46.0000 Z-0.2051
G0 X44.0000 Z0.7949
G0 X40.0000 Z0.6923
G1 X40.0000 Z-50.8000
G0 X42.0000 Z-49.8000
G0 X42.0000 Z-0.3077
G0 X40.0000 Z0.6923
G0 X36.0000 Z0.5897
G1 X36.0000 Z-50.8000
G0 X38.0000 Z-49.8000
G0 X38.0000 Z-0.4103
G0 X36.0000 Z0.5897
G0 X32.0000 Z0.4872
G1 X32.0000 Z-50.8000
G0 X34.0000 Z-49.8000
G0 X34.0000 Z-0.5128
G0 X32.0000 Z0.4872
G0 X28.0000 Z0.3846
G1 X28.0000 Z-50.8000
G0 X30.0000 Z-49.8000
G0 X30.0000 Z-0.6154
G0 X28.0000 Z0.3846
G0 X24.0000 Z0.2821
G1 X24.0000 Z-50.8000
G0 X26.0000 Z-49.8000
G0 X26.0000 Z-0.7179
G0 X24.0000 Z0.2821
G0 X20.8000 Z0.2000
G1 X20.8000 Z-0.8000
G1 X20.8000 Z-25.8000
G1 X20.8000 Z-50.8000
G1 X52.0000 Z-50.8000
G0 X52.0000 Z1.0000
G0 X20.0000 Z0.2000
G1 X20.0000 Z-0.8000 F0.1200
G1 X20.0000 Z-25.8000
G1 X20.0000 Z-50.8000
G0 X54.0000 Z-50.8000
G0 X54.0000 Z5.0000
G97 S600
M5
M9
M30
