From a8321f0aac107e5d476aea86e8d27fcc0d5ff0c0 Mon Sep 17 00:00:00 2001 From: wangdequan Date: Sun, 7 Jun 2026 21:28:06 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8C=89=E5=BB=BA=E8=AE=AE=EF=BC=8C=E7=BB=A7?= =?UTF-8?q?=E7=BB=AD=E5=B7=A5=E4=BD=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 结论:已新增 cutter compensation 平面切换拒绝 fixture,固定 vendored LinuxCNC convert_cutter_compensation_on() 与 convert_set_plane() 的错误路径;native probe 全量验证通过。 --- wasm-port/docs/drift-report.md | 3 +++ wasm-port/docs/porting-steps-standalone.md | 6 ++++++ wasm-port/docs/scope-and-baseline.md | 1 + wasm-port/docs/source-reuse-map.md | 3 +++ .../fixtures/canon_errors/cutter_comp_plane_change.expected | 6 ++++++ .../fixtures/gcode_errors/cutter_comp_plane_change.ngc | 3 +++ 6 files changed, 22 insertions(+) create mode 100644 wasm-port/tests/fixtures/canon_errors/cutter_comp_plane_change.expected create mode 100644 wasm-port/tests/fixtures/gcode_errors/cutter_comp_plane_change.ngc diff --git a/wasm-port/docs/drift-report.md b/wasm-port/docs/drift-report.md index 1df7b23..3848b25 100644 --- a/wasm-port/docs/drift-report.md +++ b/wasm-port/docs/drift-report.md @@ -55,6 +55,9 @@ semantic rewrites: - Full machine baselines beyond the current identity/trivial, `5axiskins`, TRT, delta, SCARA, PUMA, serial `genserkins`, hexapod `genhexkins`, pentapod `pentakins`, and other existing runtime probes are not established. +- Positive cutter-compensated motion is not yet a standalone runtime baseline; + current cutter compensation coverage is limited to vendored interpreter + rejection paths. - Fixture expectations are currently checked against the standalone vendored source path, not by running a native LinuxCNC binary for every fixture. diff --git a/wasm-port/docs/porting-steps-standalone.md b/wasm-port/docs/porting-steps-standalone.md index 80773c1..8048d0e 100644 --- a/wasm-port/docs/porting-steps-standalone.md +++ b/wasm-port/docs/porting-steps-standalone.md @@ -388,6 +388,12 @@ Current verified progress: `tests/fixtures/canon/plane_selection.events` pin `G17`/`G18`/`G19` plane switching and the `SELECT_PLANE` canonical boundary emitted by vendored `interp_convert.cc::convert_set_plane()`. +- `tests/fixtures/gcode_errors/cutter_comp_plane_change.ngc` and + `tests/fixtures/canon_errors/cutter_comp_plane_change.expected` pin the + LinuxCNC error path for attempting a plane change after `G41.1` enables + cutter radius compensation. The source basis is vendored + `interp_convert.cc::convert_cutter_compensation_on()` and + `interp_convert.cc::convert_set_plane()`. - `runtime/core/linuxcnc_wrap/linuxcnc_interp_minimal_runtime.cpp` now records feed/control canonical boundary calls emitted by vendored LinuxCNC conversion and queue code: `SET_TRAVERSE_RATE`, `SET_FEED_REFERENCE`, diff --git a/wasm-port/docs/scope-and-baseline.md b/wasm-port/docs/scope-and-baseline.md index f72eb1d..04fc1df 100644 --- a/wasm-port/docs/scope-and-baseline.md +++ b/wasm-port/docs/scope-and-baseline.md @@ -56,6 +56,7 @@ Negative fixture coverage includes: - zero-feed `G1` - arc radius mismatch - zero-radius arc +- cutter compensation plane-change rejection - read-only named parameter writes - read-only numbered parameter writes - missing tool diff --git a/wasm-port/docs/source-reuse-map.md b/wasm-port/docs/source-reuse-map.md index 374ab7c..0464adf 100644 --- a/wasm-port/docs/source-reuse-map.md +++ b/wasm-port/docs/source-reuse-map.md @@ -66,6 +66,9 @@ Current validation is intentionally mechanical: source-probe level. Serial `genserkins`, hexapod `genhexkins`, and pentapod `pentakins` have native runtime baselines; full runtime machine baselines for userspace genser flows are not yet established. +- Cutter compensation negative interpreter paths are fixture-covered through + vendored `interp_convert.cc`, but a positive cutter-compensated motion + runtime baseline is not yet established for the standalone harness. - Browser/WASM C ABI and JS SDK layers are not yet built for the full interpreter/planner core. - OPFS persistence is not yet connected to INI, tool table, parameter file, or diff --git a/wasm-port/tests/fixtures/canon_errors/cutter_comp_plane_change.expected b/wasm-port/tests/fixtures/canon_errors/cutter_comp_plane_change.expected new file mode 100644 index 0000000..40d967e --- /dev/null +++ b/wasm-port/tests/fixtures/canon_errors/cutter_comp_plane_change.expected @@ -0,0 +1,6 @@ +execute_line_1=0 +execute_line_2=0 +execute_line_3=5 +error_text=Cannot change planes with cutter radius compensation on +canon_event=COMMENT: interpreter: cutter radius compensation on left +absent=canon_event=SELECT_PLANE plane=3 diff --git a/wasm-port/tests/fixtures/gcode_errors/cutter_comp_plane_change.ngc b/wasm-port/tests/fixtures/gcode_errors/cutter_comp_plane_change.ngc new file mode 100644 index 0000000..d56c1a2 --- /dev/null +++ b/wasm-port/tests/fixtures/gcode_errors/cutter_comp_plane_change.ngc @@ -0,0 +1,3 @@ +G90 G17 G0 X0 Y0 +G41.1 D0.2 +G18