630 lines
18 KiB
Markdown
630 lines
18 KiB
Markdown
# 05-验收证据
|
||
|
||
## evidence 字段与路径对比实现验收
|
||
|
||
### 命令
|
||
|
||
```bash
|
||
npm --prefix web-rtcp-5axis-xyzbc-trt-sim-plan/app run smoke:node
|
||
python3 -m py_compile web-rtcp-5axis-xyzbc-trt-sim-plan/tools/collect-native-xyzbc-trt-evidence.py
|
||
npm --prefix web-rtcp-5axis-xyzbc-trt-sim-plan/app run evidence:web
|
||
npm --prefix web-rtcp-5axis-xyzbc-trt-sim-plan/app run evidence:compare
|
||
npm --prefix web-rtcp-5axis-xyzbc-trt-sim-plan/app run build
|
||
```
|
||
|
||
### 结果
|
||
|
||
```text
|
||
xyzbc_trt_web_app_smoke=ok
|
||
collect-native-xyzbc-trt-evidence.py py_compile=ok
|
||
web_xyzbc_trt_evidence=.../working/evidence/web-xyzbc-trt-evidence.json
|
||
compare_xyzbc_trt_status=fail fail_count=5
|
||
gmoccapy_static_build=ok
|
||
```
|
||
|
||
### JSON 证据
|
||
|
||
```text
|
||
web-rtcp-5axis-xyzbc-trt-sim-plan/working/evidence/web-xyzbc-trt-evidence.json
|
||
web-rtcp-5axis-xyzbc-trt-sim-plan/working/evidence/compare-xyzbc-trt-evidence.json
|
||
```
|
||
|
||
当前 Web evidence 已包含:
|
||
|
||
```text
|
||
pathSampling.samplePeriodMs = 20
|
||
previewPath.samplePeriodMs = 20
|
||
executionPath.samplePeriodMs = 20
|
||
startupSequence
|
||
iniDisplay
|
||
halNets
|
||
kinematicsPins
|
||
axisJointLimits
|
||
switchkinsTransitions
|
||
uiEquivalence
|
||
vismachEquivalent
|
||
ngcguiSubroutines
|
||
demoPrograms
|
||
```
|
||
|
||
当前 compare evidence 已包含:
|
||
|
||
```text
|
||
pathComparison.previewVsPreview
|
||
pathComparison.executionVsExecution
|
||
pathComparison.previewVsExecutionNative
|
||
pathComparison.previewVsExecutionWeb
|
||
```
|
||
|
||
结论:
|
||
|
||
- 静态/profile/staging/evidence 字段已实现并通过 Node smoke。
|
||
- compare 仍保持失败是正确结果:Web WASM artifact、preview path 和 execution path 已具备,native evidence 尚未用新基线重采集 path 样本。
|
||
- `npm run build` 当前已通过,说明目标 app 可在现有 WASM artifact 下完成静态构建。
|
||
|
||
## Web task/HAL executionPath 采集验收
|
||
|
||
### 命令
|
||
|
||
```bash
|
||
npm --prefix web-rtcp-5axis-xyzbc-trt-sim-plan/app run evidence:web
|
||
npm --prefix web-rtcp-5axis-xyzbc-trt-sim-plan/app run evidence:compare
|
||
npm --prefix web-rtcp-5axis-xyzbc-trt-sim-plan/app run smoke:node
|
||
npm --prefix web-rtcp-5axis-xyzbc-trt-sim-plan/app run build
|
||
```
|
||
|
||
### 结果
|
||
|
||
```text
|
||
web_xyzbc_trt_evidence=.../working/evidence/web-xyzbc-trt-evidence.json
|
||
compare_xyzbc_trt_status=fail fail_count=5
|
||
xyzbc_trt_web_app_smoke=ok
|
||
gmoccapy_static_build=ok
|
||
```
|
||
|
||
### JSON 摘要
|
||
|
||
```text
|
||
web.wasm.ready = true
|
||
web.blockers = []
|
||
web.previewPath.samplePeriodMs = 20
|
||
web.previewPath.sampleCount = 3074
|
||
web.executionPath.samplePeriodMs = 20
|
||
web.executionPath.sampleCount = 569
|
||
web.executionPath.source = web-linuxcnc-task-hal-execution
|
||
web.executionPath.taskHal.completed = true
|
||
compare.summary.passCount = 18
|
||
compare.summary.failCount = 5
|
||
```
|
||
|
||
结论:
|
||
|
||
- Web 侧 `previewPath` 已由 `linuxcnc_interp`/TP WASM 轨迹重采样为 20ms。
|
||
- Web 侧 `executionPath` 已由 `linuxcnc_task_hal` WASM 执行反馈生成 20ms 样本。
|
||
- compare 剩余 5 项失败均来自 native evidence 尚无 `previewPath`/`executionPath` 样本和采样周期字段。
|
||
|
||
## DOCX 整合验收
|
||
|
||
### 源文件
|
||
|
||
```text
|
||
web-rtcp-5axis-xyzbc-trt-sim-plan/doc/xyzbc-trt-web-cnc-simulation-design-task-and-technical-plan.docx
|
||
```
|
||
|
||
### 输出文件
|
||
|
||
```text
|
||
web-rtcp-5axis-xyzbc-trt-sim-plan/working/09-设计任务书与技术方案整合.md
|
||
```
|
||
|
||
### 包结构检查结论
|
||
|
||
```text
|
||
DOCX 正文段落数:507
|
||
DOCX 图片数:5
|
||
图片文件:
|
||
- word/media/xyzbc-trt-axis-window.png
|
||
- word/media/xyzbc-trt-desktop.png
|
||
- word/media/xyzbc-trt-json-compare-flow.png
|
||
- word/media/xyzbc-trt-logic-map.png
|
||
- word/media/xyzbc-trt-web-architecture.png
|
||
```
|
||
|
||
### Markdown 输出检查
|
||
|
||
```bash
|
||
wc -l web-rtcp-5axis-xyzbc-trt-sim-plan/working/09-设计任务书与技术方案整合.md
|
||
rg -n "^## |图 1|图 2|图 3|图 4|图 5|状态联锁|Evidence JSON|开发任务分解|验收标准|风险" web-rtcp-5axis-xyzbc-trt-sim-plan/working/09-设计任务书与技术方案整合.md
|
||
rg -n "!\\[" web-rtcp-5axis-xyzbc-trt-sim-plan/working/09-设计任务书与技术方案整合.md
|
||
```
|
||
|
||
结果:
|
||
|
||
```text
|
||
364 web-rtcp-5axis-xyzbc-trt-sim-plan/working/09-设计任务书与技术方案整合.md
|
||
检索到 1-11 章关键章节。
|
||
检索到 5 张图片引用,均指向 ../doc/assets/。
|
||
```
|
||
|
||
结论:
|
||
|
||
- DOCX 任务书已整合到 `working/09-设计任务书与技术方案整合.md`。
|
||
- 该 Markdown 保留任务书、技术方案、开发任务分解、验收标准、风险控制、源码级程序逻辑分析和状态联锁章节。
|
||
- `working/README.md` 和 `04-任务矩阵.md` 已登记该整合项。
|
||
|
||
## 本轮命令证据
|
||
|
||
### 读取对标文档
|
||
|
||
```bash
|
||
sed -n '1,240p' web-rtcp-5axis-xyzbc-trt-sim-plan/doc/xyzbc-trt-runtime-files.md
|
||
sed -n '241,520p' web-rtcp-5axis-xyzbc-trt-sim-plan/doc/xyzbc-trt-runtime-files.md
|
||
```
|
||
|
||
结论:
|
||
|
||
- `xyzbc-trt.ini` 使用 `DISPLAY=axis`、`PYVCP=./xyzbc-trt.xml`、`OPEN_FILE=./demos/xyzbc_switchkins.ngc`。
|
||
- `switchkins_postgui.hal` 连接 PyVCP 按钮到 `halui.mdi-command-00/01/02`。
|
||
- `M429/M428/M430` 分别选择 identity、XYZBC TCP、userk。
|
||
|
||
### 检查 WASM 支撑
|
||
|
||
```bash
|
||
rg -n "xyzbc|xyzbc-trt|supportedLinuxCncKinematicsModules|linuxcnc_xyzbc" wasm-port web-rtcp-5axis-sim-plan/tests web-rtcp-5axis-sim-plan/app/src
|
||
```
|
||
|
||
结论:
|
||
|
||
- SDK 包含 `xyzbc-trt -> linuxcnc_xyzbc_trt_kinematics.wasm`。
|
||
- native probe 包含 `linuxcnc_xyzbc_trt_kinematics_probe.cpp`。
|
||
- remap 执行 harness 包含 `xyzbc-trt.ini`、`xyzbc_switchkins.ngc`、`boat-xyzbc.ngc`。
|
||
|
||
### 检查当前 artifact
|
||
|
||
```bash
|
||
find wasm-port/build/wasm -maxdepth 3 -type f
|
||
```
|
||
|
||
结果:
|
||
|
||
```text
|
||
find: ‘wasm-port/build/wasm’: No such file or directory
|
||
```
|
||
|
||
结论:
|
||
|
||
- 当前仓库没有已生成的 WASM artifact。
|
||
- 完整浏览器运行前必须先构建 WASM。
|
||
|
||
### 检查参数文件基线
|
||
|
||
```bash
|
||
ls -l wasm-port/vendor/linuxcnc/configs/sim/axis/vismach/5axis/table-rotary-tilting/xyzbc.var linuxcnc/configs/sim/axis/vismach/5axis/table-rotary-tilting/xyzbc.var /home/mes123456/linuxcnc-master/configs/sim/axis/vismach/5axis/table-rotary-tilting/xyzbc.var
|
||
```
|
||
|
||
结果:
|
||
|
||
```text
|
||
/home/mes123456/linuxcnc-master/configs/sim/axis/vismach/5axis/table-rotary-tilting/xyzbc.var 存在
|
||
wasm-port/vendor/.../xyzbc.var 当前不存在
|
||
linuxcnc/.../xyzbc.var 当前不存在
|
||
```
|
||
|
||
结论:
|
||
|
||
- `xyzbc.var` 是需要补充导入的运行态参数文件基线。
|
||
- 历史轮次已从 `/home/mes123456/linuxcnc-master/.../xyzbc.var` 导入到 `wasm-port/vendor/linuxcnc/.../xyzbc.var`,并加入 `wasm-port/tools/source-manifest.txt`;后续若以 `/home/mes123456/cnc_wams/linuxcnc` 为新 native 基线,应重新核对该参数文件是否与当前运行树一致。
|
||
|
||
## 已运行验收
|
||
|
||
### native 基线切换验收
|
||
|
||
后续真实 LinuxCNC 对标基线统一为:
|
||
|
||
```text
|
||
/home/mes123456/cnc_wams/linuxcnc
|
||
```
|
||
|
||
必须先确认这些文件存在:
|
||
|
||
```bash
|
||
test -x /home/mes123456/cnc_wams/linuxcnc/scripts/rip-environment
|
||
test -x /home/mes123456/cnc_wams/linuxcnc/bin/axis
|
||
test -x /home/mes123456/cnc_wams/linuxcnc/bin/xyzbc-trt-gui
|
||
test -f /home/mes123456/cnc_wams/linuxcnc/rtlib/xyzbc-trt-kins.so
|
||
test -f /home/mes123456/cnc_wams/linuxcnc/configs/sim/axis/vismach/5axis/table-rotary-tilting/xyzbc-trt.ini
|
||
```
|
||
|
||
本轮自动检查结果:
|
||
|
||
```text
|
||
scripts/rip-environment: ok
|
||
scripts/linuxcnc: ok
|
||
bin/axis: ok
|
||
bin/xyzbc-trt-gui: ok
|
||
bin/milltask: ok
|
||
bin/linuxcncsvr: ok
|
||
bin/halui: ok
|
||
rtlib/xyzbc-trt-kins.so: ok
|
||
rtlib/tpmod.so: ok
|
||
lib/python/linuxcnc.so: ok
|
||
xyzbc-trt.ini: ok
|
||
```
|
||
|
||
说明:
|
||
|
||
- native evidence 的 `sourceRoot` 后续必须写为 `/home/mes123456/cnc_wams/linuxcnc`。
|
||
- `/home/mes123456/linuxcnc-master` 只作为历史运行参考;新一轮 Web 对标和 compare 以 `/home/mes123456/cnc_wams/linuxcnc` 的真实执行结果为准。
|
||
|
||
### LinuxCNC RIP 编译证据
|
||
|
||
执行命令:
|
||
|
||
```bash
|
||
cd /home/mes123456/cnc_wams/linuxcnc/src
|
||
./autogen.sh
|
||
./configure --with-realtime=uspace --disable-build-documentation
|
||
env -u DEBUG make -j"$(nproc)"
|
||
sudo -n make setuid
|
||
```
|
||
|
||
关键过程:
|
||
|
||
- 首次直接执行 `make -j"$(nproc)"` 失败,原因是当前 shell 环境存在 `DEBUG=release`,LinuxCNC Makefile 将 `$(DEBUG)` 拼入编译参数,导致 `gcc/c++` 把裸参数 `release` 当作输入文件。
|
||
- 使用 `env -u DEBUG make -j"$(nproc)"` 重新编译通过。
|
||
- `sudo -n make setuid` 成功设置 `bin/rtapi_app` 和 `bin/linuxcnc_module_helper` 的 root/setuid 权限。
|
||
|
||
验证命令:
|
||
|
||
```bash
|
||
source /home/mes123456/cnc_wams/linuxcnc/scripts/rip-environment >/dev/null
|
||
command -v linuxcnc
|
||
command -v axis
|
||
command -v halcmd
|
||
python3 - <<'PY'
|
||
import linuxcnc
|
||
print("python_linuxcnc_import=ok")
|
||
print("linuxcnc_module=", linuxcnc.__file__)
|
||
PY
|
||
```
|
||
|
||
验证结果:
|
||
|
||
```text
|
||
/home/mes123456/cnc_wams/linuxcnc/scripts/linuxcnc
|
||
/home/mes123456/cnc_wams/linuxcnc/bin/axis
|
||
/home/mes123456/cnc_wams/linuxcnc/bin/halcmd
|
||
python_linuxcnc_import=ok
|
||
linuxcnc_module= /home/mes123456/cnc_wams/linuxcnc/lib/python/linuxcnc.so
|
||
```
|
||
|
||
### `xyzbc-trt` 快捷方式与执行证据
|
||
|
||
快捷方式路径:
|
||
|
||
```text
|
||
/home/mes123456/cnc_wams/linuxcnc/linuxcnc-rtcp-5axis-shortcuts/table-rotary-tilting/xyzbc-trt.desktop
|
||
```
|
||
|
||
快捷方式内容:
|
||
|
||
```text
|
||
Exec=/home/mes123456/cnc_wams/linuxcnc/scripts/rip-environment linuxcnc /home/mes123456/cnc_wams/linuxcnc/configs/sim/axis/vismach/5axis/table-rotary-tilting/xyzbc-trt.ini
|
||
Icon=/home/mes123456/cnc_wams/linuxcnc/linuxcncicon.png
|
||
```
|
||
|
||
执行方式:
|
||
|
||
```bash
|
||
setsid bash -lc 'cd /home/mes123456/cnc_wams/linuxcnc && exec /home/mes123456/cnc_wams/linuxcnc/scripts/rip-environment linuxcnc /home/mes123456/cnc_wams/linuxcnc/configs/sim/axis/vismach/5axis/table-rotary-tilting/xyzbc-trt.ini' \
|
||
> /tmp/xyzbc-trt-cnc_wams-linuxcnc.log 2>&1 < /dev/null &
|
||
```
|
||
|
||
当前进程证据:
|
||
|
||
```text
|
||
/bin/bash /home/mes123456/cnc_wams/linuxcnc/scripts/linuxcnc .../xyzbc-trt.ini
|
||
linuxcncsvr -ini /home/mes123456/cnc_wams/linuxcnc/.../xyzbc-trt.ini
|
||
/home/mes123456/cnc_wams/linuxcnc/bin/rtapi_app load tpmod
|
||
milltask -ini /home/mes123456/cnc_wams/linuxcnc/.../xyzbc-trt.ini
|
||
halui -ini /home/mes123456/cnc_wams/linuxcnc/.../xyzbc-trt.ini
|
||
/usr/bin/python3.13 /home/mes123456/cnc_wams/linuxcnc/bin/hal_manualtoolchange
|
||
/usr/bin/python3.13 /home/mes123456/cnc_wams/linuxcnc/bin/xyzbc-trt-gui
|
||
/usr/bin/python3.13 /home/mes123456/cnc_wams/linuxcnc/bin/axis -ini /home/mes123456/cnc_wams/linuxcnc/.../xyzbc-trt.ini
|
||
```
|
||
|
||
HAL/Python 验证:
|
||
|
||
```text
|
||
motion.switchkins-type = 0
|
||
loaded file = ./demos/xyzbc_switchkins.ngc
|
||
axis_mask = 55
|
||
position = [0.0, 0.0, 0.0, 0.0, 0.0]
|
||
```
|
||
|
||
目标 Node smoke:
|
||
|
||
```bash
|
||
npm --prefix web-rtcp-5axis-xyzbc-trt-sim-plan/app run smoke:node
|
||
```
|
||
|
||
实际输出:
|
||
|
||
```text
|
||
xyzbc_trt_web_app_smoke=ok
|
||
```
|
||
|
||
静态 diff 检查:
|
||
|
||
```bash
|
||
git diff --check -- web-rtcp-5axis-xyzbc-trt-sim-plan
|
||
```
|
||
|
||
实际结果:无输出,退出码为 0。
|
||
|
||
WASM artifact 检查:
|
||
|
||
```bash
|
||
find wasm-port/build/wasm -maxdepth 3 -type f
|
||
```
|
||
|
||
实际输出:
|
||
|
||
```text
|
||
find: ‘wasm-port/build/wasm’: No such file or directory
|
||
```
|
||
|
||
完整 WASM 验收:
|
||
|
||
```bash
|
||
wasm-port/tools/build_kinematics_wasm.sh
|
||
wasm-port/tools/build_wasm_core.sh
|
||
wasm-port/tools/build_tp_wasm.sh
|
||
wasm-port/tools/build_task_hal_wasm.sh
|
||
wasm-port/tests/wasm/node/verify_kinematics_wasm.sh
|
||
wasm-port/tests/wasm/node/verify_interp_wasm.sh
|
||
wasm-port/tests/wasm/node/verify_task_hal_wasm.sh
|
||
```
|
||
|
||
### native/Web JSON 证据
|
||
|
||
真实 native 采集命令:
|
||
|
||
```bash
|
||
/home/mes123456/cnc_wams/linuxcnc/scripts/rip-environment \
|
||
python3 web-rtcp-5axis-xyzbc-trt-sim-plan/tools/collect-native-xyzbc-trt-evidence.py --run --timeout 90
|
||
```
|
||
|
||
输出:
|
||
|
||
```text
|
||
native_xyzbc_trt_evidence=/home/mes123456/cnc_wams/web-rtcp-5axis-xyzbc-trt-sim-plan/working/evidence/native-xyzbc-trt-evidence.json
|
||
```
|
||
|
||
结果摘要:
|
||
|
||
```text
|
||
status=ok
|
||
executionMode=auto-run
|
||
commandResult.status=completed
|
||
commandResult.events=1462
|
||
```
|
||
|
||
Web 采集命令:
|
||
|
||
```bash
|
||
npm --prefix web-rtcp-5axis-xyzbc-trt-sim-plan/app run evidence:web
|
||
```
|
||
|
||
输出:
|
||
|
||
```text
|
||
web_xyzbc_trt_evidence=/home/mes123456/cnc_wams/web-rtcp-5axis-xyzbc-trt-sim-plan/working/evidence/web-xyzbc-trt-evidence.json
|
||
```
|
||
|
||
结果摘要:
|
||
|
||
```text
|
||
profileDefaultXyzbc=true
|
||
iniReady=true
|
||
opfsStaged=true
|
||
pyvcpXmlStaged=true
|
||
remapsStaged=true
|
||
toolTableStaged=true
|
||
parameterFileStaged=true
|
||
defaultProgramStaged=true
|
||
wasmArtifactsReady=false
|
||
```
|
||
|
||
对比命令:
|
||
|
||
```bash
|
||
npm --prefix web-rtcp-5axis-xyzbc-trt-sim-plan/app run evidence:compare
|
||
```
|
||
|
||
输出:
|
||
|
||
```text
|
||
compare_xyzbc_trt_evidence=/home/mes123456/cnc_wams/web-rtcp-5axis-xyzbc-trt-sim-plan/working/evidence/compare-xyzbc-trt-evidence.json
|
||
compare_xyzbc_trt_status=fail fail_count=1
|
||
```
|
||
|
||
当前结论:
|
||
|
||
- 12 项对比中 11 项通过。
|
||
- 唯一失败项是 `required WASM artifacts available`。
|
||
- 当前环境已安装 `emcc 6.0.2`;剩余前置是执行 `wasm-port` 构建脚本生成 artifact,并重跑 evidence。
|
||
|
||
### 全量对标 JSON 验收要求
|
||
|
||
后续 native/Web evidence JSON 必须按 `07-全量对标追踪矩阵.md` 增加这些顶层或等效字段:
|
||
|
||
```text
|
||
startupSequence
|
||
iniDisplay
|
||
halNets
|
||
kinematicsPins
|
||
axisJointLimits
|
||
switchkinsTransitions
|
||
toolTable
|
||
toolOffsetFlow
|
||
uiEquivalence
|
||
vismachEquivalent
|
||
ngcguiSubroutines
|
||
demoPrograms
|
||
pathSampling
|
||
previewPath
|
||
executionPath
|
||
```
|
||
|
||
`compare-xyzbc-trt-evidence.json` 必须新增或扩展这些检查类别:
|
||
|
||
```text
|
||
startup-sequence
|
||
ini-display
|
||
hal-nets
|
||
kinematics-pins
|
||
axis-joint-limits
|
||
switchkins-transitions
|
||
tool-offset-flow
|
||
ui-equivalence
|
||
vismach-equivalence
|
||
ngcgui-subroutines
|
||
demo-programs
|
||
path-preview
|
||
path-execution
|
||
path-comparison
|
||
```
|
||
|
||
必须逐项验证:
|
||
|
||
- `.desktop/rip-environment/linuxcnc` 启动顺序在 Web 中有等效 `startupSequence`。
|
||
- `[DISPLAY]` 的 `DISPLAY`、`GEOMETRY`、`OPEN_FILE`、`PYVCP`、`JOG_AXES`、`POSITION_OFFSET`、`POSITION_FEEDBACK`、`MAX_*`、`TOOL_EDITOR`、`NGCGUI_*` 有 Web 等效字段或 UI。
|
||
- `[TRAJ]`、`[KINS]`、`[EMCMOT]`、`[TASK]`、`[EMCIO]` 的关键配置进入 JSON。
|
||
- `switchkins_postgui.hal` 中 `pyvcp.*` 到 `halui.mdi-command-*` 的连接进入 `halNets`。
|
||
- `basic_sim.tcl` 的模拟 joint/home/spindle/manualtoolchange 语义由 task/HAL evidence 证明。
|
||
- `xyzbc-trt-gui.py` 的 HAL pin 和模型层级由 `vismachEquivalent` 证明。
|
||
- `xyzbc-trt-kins` 的 offset、rot-point、conventional-directions、tool-offset pin 由 `kinematicsPins` 证明。
|
||
- `xyzbc_switchkins_sub.ngc`、`centering.ngc`、`helix_bc.ngc`、`xyzbc_switchkins.ngc`、`boat-xyzbc.ngc` 都进入 staging 和可执行验收。
|
||
- `xyzbc-trt.tbl` 的 `T1 P1 D1`、`T2 P2 Z10 D8` 解析后影响 tool offset、kinematics 和 Web 3D 刀具显示。
|
||
|
||
### 刀具预览/执行路径 JSON 验收要求
|
||
|
||
后续 native/Web evidence JSON 必须增加刀具预览路径和刀具执行路径:
|
||
|
||
```text
|
||
working/evidence/native-xyzbc-trt-evidence.json.pathSampling.samplePeriodMs = 20
|
||
working/evidence/web-xyzbc-trt-evidence.json.pathSampling.samplePeriodMs = 20
|
||
working/evidence/native-xyzbc-trt-evidence.json.previewPath.samples[]
|
||
working/evidence/native-xyzbc-trt-evidence.json.executionPath.samples[]
|
||
working/evidence/web-xyzbc-trt-evidence.json.previewPath.samples[]
|
||
working/evidence/web-xyzbc-trt-evidence.json.executionPath.samples[]
|
||
working/evidence/compare-xyzbc-trt-evidence.json.pathComparison
|
||
```
|
||
|
||
采样要求:
|
||
|
||
- `samplePeriodMs` 固定为 `20`,native/Web 两侧必须一致。
|
||
- 样本必须通过 `sampleIndex` 和 `timeMs` 对齐。
|
||
- 若原始采集周期不同,采集脚本或 compare 脚本必须重采样为 20ms 后再比较。
|
||
- `previewPath` 只能表示预览/planner 路径;`executionPath` 必须来自真实执行反馈或 Web WASM task/HAL 执行反馈,不能用预览路径替代。
|
||
|
||
每个样本必须包含:
|
||
|
||
```text
|
||
sampleIndex
|
||
timeMs
|
||
line
|
||
motionType
|
||
activeKinematics
|
||
tool.id/tool.length/tool.diameter
|
||
joint.x/joint.y/joint.z/joint.b/joint.c
|
||
tcp.x/tcp.y/tcp.z
|
||
toolAxis.i/toolAxis.j/toolAxis.k
|
||
feed
|
||
spindle
|
||
```
|
||
|
||
compare 验收项:
|
||
|
||
```text
|
||
pathComparison.previewVsPreview
|
||
pathComparison.executionVsExecution
|
||
pathComparison.previewVsExecutionNative
|
||
pathComparison.previewVsExecutionWeb
|
||
```
|
||
|
||
每个对比项至少输出:
|
||
|
||
```text
|
||
maxTcpErrorMm
|
||
rmsTcpErrorMm
|
||
maxJointError
|
||
rmsJointError
|
||
maxToolAxisAngleDeg
|
||
sampleCountDelta
|
||
missingSamples
|
||
```
|
||
|
||
当前状态:
|
||
|
||
- `web-xyzbc-trt-evidence.json` 已通过采集脚本重新生成,`wasmArtifactsReady=true`、`missing=[]`。
|
||
- Web preview path 已由 `linuxcnc_interp` WASM 生成 6174 个 20ms 样本。
|
||
- Web execution path 采集仍未实现,当前 blocker 为 `web-execution-path-unavailable`。
|
||
- native preview/execution path 仍需用 `/home/mes123456/cnc_wams/linuxcnc` 真实运行实例重采集。
|
||
- `compare-xyzbc-trt-evidence.json` 当前 17/23 通过,剩余 6 项均与 native path 样本或 Web execution path 样本缺失有关。
|
||
|
||
### WASM artifact 验收记录
|
||
|
||
本轮已生成并核对以下目标 artifact:
|
||
|
||
```text
|
||
wasm-port/build/wasm/core/linuxcnc_interp.js
|
||
wasm-port/build/wasm/core/linuxcnc_interp.wasm
|
||
wasm-port/build/wasm/kinematics/linuxcnc_xyzbc_trt_kinematics.js
|
||
wasm-port/build/wasm/kinematics/linuxcnc_xyzbc_trt_kinematics.wasm
|
||
wasm-port/build/wasm/tp/linuxcnc_tp.js
|
||
wasm-port/build/wasm/tp/linuxcnc_tp.wasm
|
||
wasm-port/build/wasm/task-hal/linuxcnc_task_hal.js
|
||
wasm-port/build/wasm/task-hal/linuxcnc_task_hal.wasm
|
||
```
|
||
|
||
验证命令结果:
|
||
|
||
```text
|
||
node tests/node/verify_xyzbc_trt_web_app.mjs -> xyzbc_trt_web_app_smoke=ok
|
||
SKIP_KINEMATICS_BUILD=1 wasm-port/tests/wasm/node/verify_kinematics_wasm.sh -> kinematics_wasm_node_smoke=ok
|
||
SKIP_TP_BUILD=1 wasm-port/tests/wasm/node/verify_tp_wasm.sh -> tp_wasm_node_smoke=ok
|
||
SKIP_TASK_HAL_BUILD=1 wasm-port/tests/wasm/node/verify_task_hal_wasm.sh -> linuxcnc_task_runtime_smoke=ok
|
||
```
|
||
|
||
补充 interpreter/remap 验收:
|
||
|
||
```text
|
||
SKIP_INTERP_BUILD=1 wasm-port/tests/wasm/node/verify_interp_wasm.sh -> interp_wasm_node_smoke=ok
|
||
wasm-port/tests/wasm/node/verify_interp_wasm.sh -> interp_wasm_node_smoke=ok
|
||
```
|
||
|
||
修复依据:`interp_g10_l11_wasm` 的实际 WASM 输出与 `wasm-port/vendor/linuxcnc/tests/interp/g10/g10-l11/expected` 一致,均为 `SET_G92_OFFSET x=-43.0622 y=-47.4282 z=-72`;原 Node 验收脚本中的 `x=-41.1962 y=-46.1962 z=-72` 为过期期望值。
|
||
|
||
## 页面证据
|
||
|
||
目标页面:
|
||
|
||
```text
|
||
web-rtcp-5axis-xyzbc-trt-sim-plan/app/index.html
|
||
```
|
||
|
||
开发服务:
|
||
|
||
```bash
|
||
cd web-rtcp-5axis-xyzbc-trt-sim-plan/app
|
||
npm run dev
|
||
```
|
||
|
||
URL:
|
||
|
||
```text
|
||
http://127.0.0.1:4174/
|
||
```
|