===== case 0000 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=0.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: pitch must be greater than 0
===== case 0001 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=-1.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: thread depth cannot be negative - 0 is what means 'work it out from the form and the insert radius'
===== case 0002 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=3.6806 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: depth 3.6806 is deeper than the pitch 3.0000. Depth here is a RADIUS - 0.613 x pitch for a 60 degree thread - while a G76 K word is a diameter, so halve it
===== case 0003 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=-25.0 =====
!! ValueError: threading: start Z and end Z are the same - the thread has no length
===== case 0004 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=0.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: degression must be at least 1.0 - 1.0 is equal depth per pass, 2.0 equal area
===== case 0005 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=5.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: first-pass depth 5.0000 is deeper than the full thread depth 1.8403
===== case 0006 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=-1.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
(Lathe EXTERNAL thread - longhand G33, generated by the conversational tab)
(Set work zero at the finished face, on the spindle centreline)
(G76 cannot cut a taper - its drive line is parallel to Z - so this is direct G33)
(Straight thread  crest dia 24.0000 Z3.0000 -> dia 24.0000 Z-25.0000)
(Pitch 3.0000  full depth 1.8403 rad = 3.6806 dia  crest is the major dia, cutting inward)
(Depth computed for ISO / Unified 60 deg, insert tip radius 0.4330 - FULL FORM)
(Infeed first-pass depth + degression - 6 cutting passes + 1 spring, degression 1.50, compound 29.5 deg)
(Tool T0909   G97 constant 400 rpm)
(G97 throughout: CSS would move the spindle speed during a synchronised cut)
(Retract dia 28.0000   clearance Z 25.0000   coolant flood   wcs G54)
(Every pass starts at the spindle index so the passes line up. The start Z must be)
(clear of the material - there is no ramp in unless an entry taper is set.)
(Needs the spindle encoder: G33 waits on index-enable and at-speed.)
(=== conversational block - do not edit; lets the panel reload this file ===)
(CONV1 cycle=od_thread)
(CONV1 tool=9 x_start=24 z_start=3 x_end=24 z_end=-25 pitch=3)
(CONV1 thread_form=0 insert_r=0 depth=0 infeed_mode=0 first_depth=-1 n_passes=8)
(CONV1 degression=1.5 spring_passes=1 compound_angle=29.5 lead_in=0 taper_ends=0 exit_taper=0)
(CONV1 rpm=400 pullout_feed=0 clearance=4 clear_z=25 coolant_type=1)
(CONV1 END)
G18 G21 G7 G90 G95 G40
G64 P0.02
G54
G30
T0909
G97 S400 M3
M8
G0 X28.0000
(pass 1 of 6 - depth 0.5573 rad)
G0 Z2.6847
G0 X22.8853
G33 X22.8853 Z-24.2741 K3.000000
G0 X28.0000
(pass 2 of 6 - depth 0.8847 rad)
G0 Z2.4994
G0 X22.2305
G33 X22.2305 Z-24.4594 K3.000000
G0 X28.0000
(pass 3 of 6 - depth 1.1593 rad)
G0 Z2.3441
G0 X21.6814
G33 X21.6814 Z-24.6147 K3.000000
G0 X28.0000
(pass 4 of 6 - depth 1.4044 rad)
G0 Z2.2054
G0 X21.1912
G33 X21.1912 Z-24.7534 K3.000000
G0 X28.0000
(pass 5 of 6 - depth 1.6297 rad)
G0 Z2.0780
G0 X20.7406
G33 X20.7406 Z-24.8808 K3.000000
G0 X28.0000
(pass 6 of 6 - depth 1.8403 rad)
G0 Z1.9588
G0 X20.3194
G33 X20.3194 Z-25.0000 K3.000000
G0 X28.0000
(spring pass 1)
G0 Z1.9588
G0 X20.3194
G33 X20.3194 Z-25.0000 K3.000000
G0 X28.0000
G0 X28.0000
G0 Z25.0000
M5
M9
M30
===== case 0007 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=3.0 depth=0.0 exit_taper=0.0 first_depth=0.001 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: that first pass and degression need more than 500 passes - take a deeper first cut or lower the degression
===== case 0008 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=-1.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: insert tip radius cannot be negative - 0 means full form
===== case 0009 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=5.0 lead_in=0.0 n_passes=8 pitch=1.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: a 5.0000 insert radius is too blunt for a 1.0000 pitch ISO / Unified 60 deg thread - it cannot reach the root at all
===== case 0010 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=7 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: thread form must be 0 (ISO / Unified 60 deg), 1 (Whitworth / BSP 55 deg) or 2 (NPT taper pipe 60 deg)
===== case 0011 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=3 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: thread form must be 0 (ISO / Unified 60 deg), 1 (Whitworth / BSP 55 deg) or 2 (NPT taper pipe 60 deg)
===== case 0012 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=5.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=2 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: a 5.0000 insert radius is too blunt for a 3.0000 pitch NPT taper pipe 60 deg thread - it cannot reach the root at all
===== case 0013 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=0.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=2 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: pitch must be greater than 0
===== case 0014 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=1 insert_r=0.0 lead_in=0.0 n_passes=0 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: pass count must be at least 1
===== case 0015 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=1 insert_r=0.0 lead_in=0.0 n_passes=900 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: pass count must be 500 or fewer
===== case 0016 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=7 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: infeed mode must be 0 (first-pass depth) or 1 (pass count)
===== case 0017 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=-2 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: spring passes cannot be negative
===== case 0018 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=40.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=3 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: a 40.000 run-out taper is more than half the 26.959 long thread pass
===== case 0019 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=7 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: run-out taper must be 0 none, 1 entry, 2 exit or 3 both
===== case 0020 | clear_z=25.0 clearance=4.0 compound_angle=95.0 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: compound angle must be between -90 and 90
===== case 0021 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=-1.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: lead-in and taper distance cannot be negative
===== case 0022 | clear_z=25.0 clearance=-3.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=24.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: clearance must be greater than 0
===== case 0023 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=2.0 x_start=2.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: a 1.1593 deep pass reaches the spindle centreline at Z2.344 - check the X values and the depth
===== case 0024 | clear_z=25.0 clearance=4.0 compound_angle=29.5 coolant_type=1 degression=1.5 depth=0.0 exit_taper=0.0 first_depth=0.0 infeed_mode=0 insert_r=0.0 lead_in=0.0 n_passes=8 pitch=3.0 pullout_feed=0.0 rpm=400.0 spring_passes=1 taper_ends=0 thread_form=0 tool=9 x_end=24.0 x_start=0.0 z_end=-25.0 z_start=3.0 =====
!! ValueError: threading: start and end X must be greater than 0
