step-examples/12-8-mixed/M169.stp
Sources
- 16-iso-spec ISO 10303-238 §5.8 turning_roughing stepover-vs-nose-radius rule
- bug-reporter language: "AP238 lathe stepover too big", "STEP-NC scallops between turn passes", "turning leaves stair-step".
Description
A `TURNING_ROUGHING` op declares a radial stepover (e.g. 4.0 mm) larger than the cutting tool's nose radius (0.8 mm). Each successive pass leaves an unsupported scallop the nose can't reach, producing a stair-stepped surface that the next pass either gouges or leaves visible. Bug-reporter language: "AP238 turning stepover > nose r", "STEP-NC roughing scallops", "lathe rough pass leaves steps".
Reproducer recipe
a `TURNING_MACHINING_TOOL` with `nose_radius = 0.8` mm; a `TURNING_ROUGHING` op with `stepover = 4.0` mm.
Expected kernel behavior
validate stepover against tool nose radius; warn or reject when the ratio leaves un-machinable scallops.
Notes
Synonyms: "AP238 stepover gouge", "STEP-NC turning rough pass scallops", "stepover larger than nose radius", "lathe stair-step finish".
Expected validation
occt=empty/empty gmsh=empty ifc=schema_n/a
Byte assertions
contains(b'AP238_STEP_NC_MIM')contains(b'TURNING_ROUGHING')contains(b'TURNING_MACHINING_TOOL')
Tier-3 assertions
shape_null == True
Live oracle output
No live oracle data — run _run_corpus to populate.
Fixture content
Show fixture bytes (with defect highlighting)
1ISO-10303-21; 2/* M169: AP238 turning_roughing stepover exceeds tool nose radius */ 3/* DEFECT: TURNING_ROUGHING stepover=4.0mm; TURNING_MACHINING_TOOL nose_radius=0.8mm */ 4/* Each pass leaves 3.2mm scallop nose cannot reach â stair-step surface */ 5/* STEP-NC programmer used tool-diameter-based stepover instead of nose-radius rule */ 6/* Per ISO 10303-238 §5.8 turning stepover must not exceed nose radius */ 7/* Byte assertion: contains(b'AP238_STEP_NC_MIM') */ 8/* Byte assertion: contains(b'TURNING_ROUGHING') */ 9/* Byte assertion: contains(b'TURNING_MACHINING_TOOL') */ 10HEADER; 11FILE_DESCRIPTION(('M169: AP238 turning_roughing stepover 4.0mm exceeds nose radius 0.8mm'),'2;1'); 12FILE_NAME('M169.stp','2026-06-21T00:00:00',(''),(''),'cad-research-suite','',''); 13/* Byte assertion: contains(b'AP238_STEP_NC_MIM') */ 14FILE_SCHEMA(('AP238_STEP_NC_MIM { 1 0 10303 238 3 1 1 1 }')); 15ENDSEC; 16DATA; 17/* Standard unit context (mm) */ 18#10=(LENGTH_UNIT()NAMED_UNIT(*)SI_UNIT(.MILLI.,.METRE.)); 19#11=(NAMED_UNIT(*)PLANE_ANGLE_UNIT()SI_UNIT($,.RADIAN.)); 20#12=(NAMED_UNIT(*)SI_UNIT($,.STERADIAN.)SOLID_ANGLE_UNIT()); 21#13=UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(0.001),#10, 22 'distance_accuracy_value','maximum model space distance between geometric entities'); 23#14=(GEOMETRIC_REPRESENTATION_CONTEXT(3) 24 GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#13)) 25 GLOBAL_UNIT_ASSIGNED_CONTEXT((#10,#11,#12)) 26 REPRESENTATION_CONTEXT('ctx','3D')); 27/* mm length unit reference for MEASURE_WITH_UNIT */ 28#15=SI_UNIT(.MILLI.,.METRE.); 29/* GEOMETRIC_CURVE_SET IS the model entity â OCC yields empty */ 30#20=GEOMETRIC_CURVE_SET('ap238-turning-roughing-stepover-exceeds-tool-nose-radius', 31 (#52,#54,#60)); 32/* WORKPLAN 'rough_turn_program' â AP238 top-level NC program */ 33#50=WORKPLAN('rough_turn_program','Rough turning workplan',(),$,(#51)); 34/* MACHINING_WORKINGSTEP links workpiece to roughing operation */ 35#51=MACHINING_WORKINGSTEP('rough_turn_step','Rough turning workingstep',#52,#60,$); 36/* Byte assertion: contains(b'TURNING_MACHINING_TOOL') */ 37/* TURNING_MACHINING_TOOL 'turn_rough_tool': nose_radius = 0.8mm */ 38#55=MEASURE_WITH_UNIT(POSITIVE_LENGTH_MEASURE(0.8),#15); 39#54=TURNING_MACHINING_TOOL('turn_rough_tool',$,#55,$,$,$,$,$,$); 40/* Byte assertion: contains(b'TURNING_ROUGHING') */ 41/* DEFECT: TURNING_ROUGHING stepover = 4.0mm > nose_radius 0.8mm */ 42/* stepover = MEASURE_WITH_UNIT(POSITIVE_LENGTH_MEASURE(4.0), mm) */ 43#53=MEASURE_WITH_UNIT(POSITIVE_LENGTH_MEASURE(4.0),#15); 44#52=TURNING_ROUGHING('roughing_pass',$,$,$,#53,$,#54); 45/* WORKPIECE 'cyl_rough_workpiece' */ 46#60=WORKPIECE('cyl_rough_workpiece','Cylindrical workpiece for rough turning',$,$,$,$,$); 47/* Product chain */ 48#100=APPLICATION_CONTEXT('mechanical design'); 49#101=PRODUCT_CONTEXT('',#100,'mechanical'); 50#102=PRODUCT('M169','M169','M169',(#101)); 51#103=PRODUCT_DEFINITION_FORMATION('','',#102); 52#104=PRODUCT_DEFINITION_CONTEXT(#100,'design'); 53#105=PRODUCT_DEFINITION('','',#103,#104); 54#106=PRODUCT_DEFINITION_SHAPE('','',#105); 55#107=SHAPE_REPRESENTATION('',(#20),#14); 56#108=SHAPE_DEFINITION_REPRESENTATION(#106,#107); 57ENDSEC; 58END-ISO-10303-21;