docs: add axis run process working set
This commit is contained in:
350
work/working8-暂停按钮/05-验收证据.md
Normal file
350
work/working8-暂停按钮/05-验收证据.md
Normal file
@@ -0,0 +1,350 @@
|
||||
# 05-验收证据
|
||||
|
||||
## 证据要求
|
||||
|
||||
每条证据必须记录:
|
||||
|
||||
- 执行时间;
|
||||
- 命令或页面;
|
||||
- 关键输出;
|
||||
- 生成文件路径;
|
||||
- 对应任务编号。
|
||||
|
||||
## 当前已有参考证据
|
||||
|
||||
### Web 前端暂停冻结历史证据
|
||||
|
||||
来源文件:
|
||||
|
||||
`/home/mes123456/cnc_wams/web-rtcp-5axis-xyzbc-trt-sim-plan/working/17-20260706-暂停按钮严格测试报告.md`
|
||||
|
||||
历史结论:
|
||||
|
||||
- `npm --prefix app run build` 通过。
|
||||
- `npm --prefix app run smoke:node` 通过。
|
||||
- `npm --prefix app run smoke:browser` 通过。
|
||||
- `trace-pause-position-json.mjs` 输出 `pause_position_status=passed-position-frozen`。
|
||||
- `verify-estop-power-home-run-pause-50ms.mjs` 输出 `verification_status=passed`。
|
||||
|
||||
注意:
|
||||
|
||||
该证据证明 Web 表层暂停冻结通过,但不能单独证明 `wasm-port` 底层已完整对标 LinuxCNC task/motion/TP 暂停链。
|
||||
|
||||
## 本轮文档建档证据
|
||||
|
||||
时间:2026-07-07
|
||||
|
||||
操作:
|
||||
|
||||
```bash
|
||||
sed -n '1,240p' web-rtcp-5axis-xyzbc-trt-sim-plan/doc/AXIS暂停按钮LinuxCNC调用链分析.md
|
||||
rg -n "pause|paused|AUTO_PAUSE|AUTO_RESUME|task_paused|interpState|EMCMOT_PAUSE|PLAN_PAUSE|runState|tbtn_pause" wasm-port web-rtcp-5axis-xyzbc-trt-sim-plan/app web-rtcp-5axis-xyzbc-trt-sim-plan/tests web-rtcp-5axis-xyzbc-trt-sim-plan/tools -S
|
||||
sed -n '600,755p' wasm-port/runtime/core/linuxcnc_wrap/linuxcnc_task_hal_wasm.cpp
|
||||
sed -n '1,460p' wasm-port/runtime/core/linuxcnc_wrap/linuxcnc_motion_runtime.c
|
||||
sed -n '1,260p' wasm-port/tests/wasm/node/verify_task_hal_wasm.mjs
|
||||
```
|
||||
|
||||
结论:
|
||||
|
||||
- 已确认 AXIS 暂停调用链和当前 WASM wrapper 差距。
|
||||
- 已确认 `work/working8` 文档体系建立。
|
||||
|
||||
对应任务:
|
||||
|
||||
- `W8-014` 部分完成:文档框架已建立,后续仍需随代码实现补证据。
|
||||
|
||||
## 待执行验收命令
|
||||
|
||||
### WASM task/motion 验收
|
||||
|
||||
对应任务:`W8-001` 至 `W8-006`
|
||||
|
||||
```bash
|
||||
cd /home/mes123456/cnc_wams/wasm-port
|
||||
./tools/build_task_hal_wasm.sh
|
||||
node tests/wasm/node/verify_task_hal_wasm.mjs
|
||||
```
|
||||
|
||||
期望输出:
|
||||
|
||||
```text
|
||||
linuxcnc_task_runtime_smoke=ok
|
||||
task_status_from_linuxcnc_runtime=ok
|
||||
task_commands_drive_motion_runtime=ok
|
||||
mdi_jog_task_motion_hal_sync=ok
|
||||
```
|
||||
|
||||
新增断言期望:
|
||||
|
||||
```text
|
||||
pause_freezes_motion_queue=ok
|
||||
resume_restores_interp_resume_state=ok
|
||||
step_returns_to_paused=ok
|
||||
```
|
||||
|
||||
### WASM TP 验收
|
||||
|
||||
对应任务:`W8-007`
|
||||
|
||||
```bash
|
||||
cd /home/mes123456/cnc_wams/wasm-port
|
||||
./tools/build_tp_wasm.sh
|
||||
node tests/wasm/node/verify_tp_wasm.mjs
|
||||
```
|
||||
|
||||
期望输出:
|
||||
|
||||
```text
|
||||
tp_wasm_node_smoke=ok
|
||||
tp_pause_resume_smoke=ok
|
||||
```
|
||||
|
||||
### Web Node 集成验收
|
||||
|
||||
对应任务:`W8-008` 至 `W8-011`
|
||||
|
||||
```bash
|
||||
cd /home/mes123456/cnc_wams/web-rtcp-5axis-xyzbc-trt-sim-plan
|
||||
npm --prefix app run build
|
||||
node tests/node/verify_run_feedback_loop.mjs
|
||||
```
|
||||
|
||||
期望输出:
|
||||
|
||||
```text
|
||||
run_feedback_status_loop_smoke=ok
|
||||
run_ready_sequence_smoke=ok
|
||||
```
|
||||
|
||||
新增断言期望:
|
||||
|
||||
```text
|
||||
pause_uses_motion_paused_gate=ok
|
||||
pause_freezes_task_hal_status_loop=ok
|
||||
```
|
||||
|
||||
### 浏览器 trace 验收
|
||||
|
||||
对应任务:`W8-012`
|
||||
|
||||
```bash
|
||||
cd /home/mes123456/cnc_wams/web-rtcp-5axis-xyzbc-trt-sim-plan
|
||||
APP_URL_PATH=/web-rtcp-5axis-xyzbc-trt-sim-plan/app/dist/index.html node tools/trace-pause-position-json.mjs
|
||||
```
|
||||
|
||||
期望输出:
|
||||
|
||||
```text
|
||||
pause_position_status=passed-position-frozen
|
||||
position_changed=false
|
||||
changed_fields=
|
||||
```
|
||||
|
||||
需要记录:
|
||||
|
||||
- `trace=.../trace.json`
|
||||
|
||||
### 50ms 长流程截图验收
|
||||
|
||||
对应任务:`W8-013`
|
||||
|
||||
```bash
|
||||
cd /home/mes123456/cnc_wams/web-rtcp-5axis-xyzbc-trt-sim-plan
|
||||
RUN_STABLE_BEFORE_FIRST_PAUSE_MS=3000 node tools/verify-estop-power-home-run-pause-50ms.mjs
|
||||
```
|
||||
|
||||
期望输出:
|
||||
|
||||
```text
|
||||
verification_status=passed
|
||||
captured_frames=...
|
||||
manifest=...
|
||||
```
|
||||
|
||||
需要记录:
|
||||
|
||||
- screenshots 目录;
|
||||
- manifest 文件;
|
||||
- 两次暂停保持阶段的 `sampleIndex`、`interpState`、`taskPaused`、`motionPaused`、`currentVelocity`。
|
||||
|
||||
## 2026-07-07 10:16 EDT 本轮完成证据
|
||||
|
||||
### WASM task/motion 验收
|
||||
|
||||
对应任务:
|
||||
|
||||
- `W8-001`
|
||||
- `W8-002`
|
||||
- `W8-003`
|
||||
- `W8-004`
|
||||
- `W8-005`
|
||||
- `W8-006`
|
||||
|
||||
命令:
|
||||
|
||||
```bash
|
||||
cd /home/mes123456/cnc_wams/wasm-port
|
||||
source /home/mes123456/emsdk/emsdk_env.sh >/dev/null && ./tools/build_task_hal_wasm.sh
|
||||
node tests/wasm/node/verify_task_hal_wasm.mjs
|
||||
```
|
||||
|
||||
关键输出:
|
||||
|
||||
```text
|
||||
linuxcnc_task_hal_wasm_build=ok
|
||||
linuxcnc_task_runtime_smoke=ok
|
||||
task_status_from_linuxcnc_runtime=ok
|
||||
task_commands_drive_motion_runtime=ok
|
||||
mdi_jog_task_motion_hal_sync=ok
|
||||
pause_freezes_motion_queue=ok
|
||||
resume_restores_interp_resume_state=ok
|
||||
step_returns_to_paused=ok
|
||||
```
|
||||
|
||||
结论:
|
||||
|
||||
- task status 已输出并维护 `interpResumeState`。
|
||||
- pause 后 `interpState=PAUSED`、`taskPaused=true`、`motion.paused=true`,连续 cycles 不推进 task line、motion line、axis pose 和 motion id。
|
||||
- resume 后恢复 `interpResumeState=READING` 并继续推进。
|
||||
- motion direct queue 验证 pause 即时生效、queue 保留、STEP 只消费一个 motion 后自动回 paused。
|
||||
|
||||
### WASM TP pause/resume 验收
|
||||
|
||||
对应任务:
|
||||
|
||||
- `W8-007`
|
||||
|
||||
命令:
|
||||
|
||||
```bash
|
||||
cd /home/mes123456/cnc_wams/wasm-port
|
||||
source /home/mes123456/emsdk/emsdk_env.sh >/dev/null && ./tools/build_tp_wasm.sh
|
||||
node tests/wasm/node/verify_tp_wasm.mjs
|
||||
```
|
||||
|
||||
关键输出:
|
||||
|
||||
```text
|
||||
tp_wasm_node_smoke=ok
|
||||
tp_pause_resume_smoke=ok
|
||||
```
|
||||
|
||||
新增 probe 断言:
|
||||
|
||||
```text
|
||||
tp_pause_rc=0
|
||||
tp_resume_rc=0
|
||||
tp_paused_velocity_zero=1
|
||||
tp_paused_position_frozen=1
|
||||
tp_resume_done=1
|
||||
tp_pause_resume_final_depth=0
|
||||
tp_pause_resume_final_pos_near_end=1
|
||||
```
|
||||
|
||||
结论:
|
||||
|
||||
- `linuxcnc_tp_wasm.c` 通过 vendored LinuxCNC `tpPause()`、`tpResume()` 验证暂停减速到零、暂停保持位置、恢复后完成队列。
|
||||
|
||||
### Web Node 集成验收
|
||||
|
||||
对应任务:
|
||||
|
||||
- `W8-008`
|
||||
- `W8-009`
|
||||
- `W8-010`
|
||||
- `W8-011`
|
||||
|
||||
命令:
|
||||
|
||||
```bash
|
||||
cd /home/mes123456/cnc_wams/web-rtcp-5axis-xyzbc-trt-sim-plan
|
||||
npm --prefix app run build
|
||||
node tests/node/verify_run_feedback_loop.mjs
|
||||
```
|
||||
|
||||
关键输出:
|
||||
|
||||
```text
|
||||
gmoccapy_static_build=ok
|
||||
run_feedback_status_loop_smoke=ok
|
||||
run_ready_sequence_smoke=ok
|
||||
pause_uses_motion_paused_gate=ok
|
||||
pause_freezes_task_hal_status_loop=ok
|
||||
```
|
||||
|
||||
结论:
|
||||
|
||||
- Web runtime `ui` 可读取 `interpResumeState`、`taskPaused`、`singleStepping`、`motionPaused`、`motionStepping`、`motionQueueDepth`。
|
||||
- `canResume` 与 `PAUSE_RESUME` 已接入 motion paused/task paused/interp paused 综合判断。
|
||||
- Node 集成断言 pause 后 `taskHalStatus.motionStatus.motion.paused=true`、`machine.motionPaused=true`、active line 和 motion program line 不推进。
|
||||
|
||||
### 浏览器暂停冻结 trace 验收
|
||||
|
||||
对应任务:
|
||||
|
||||
- `W8-012`
|
||||
|
||||
命令:
|
||||
|
||||
```bash
|
||||
cd /home/mes123456/cnc_wams/web-rtcp-5axis-xyzbc-trt-sim-plan
|
||||
APP_URL_PATH=/web-rtcp-5axis-xyzbc-trt-sim-plan/app/dist/index.html node tools/trace-pause-position-json.mjs
|
||||
```
|
||||
|
||||
关键输出:
|
||||
|
||||
```text
|
||||
pause_position_status=passed-position-frozen
|
||||
trace=/home/mes123456/cnc_wams/web-rtcp-5axis-xyzbc-trt-sim-plan/working/pause-position-traces/pause-position-20260707T140646Z/trace.json
|
||||
app_url_path=/web-rtcp-5axis-xyzbc-trt-sim-plan/app/dist/index.html
|
||||
position_changed=false
|
||||
changed_fields=
|
||||
```
|
||||
|
||||
结论:
|
||||
|
||||
- 浏览器 trace 证明暂停后 position 未变化。
|
||||
|
||||
### 50ms 长流程暂停/恢复截图验收
|
||||
|
||||
对应任务:
|
||||
|
||||
- `W8-013`
|
||||
|
||||
命令:
|
||||
|
||||
```bash
|
||||
cd /home/mes123456/cnc_wams/web-rtcp-5axis-xyzbc-trt-sim-plan
|
||||
RUN_STABLE_BEFORE_FIRST_PAUSE_MS=3000 node tools/verify-estop-power-home-run-pause-50ms.mjs
|
||||
```
|
||||
|
||||
关键输出:
|
||||
|
||||
```text
|
||||
verification_status=passed
|
||||
screenshots=/home/mes123456/cnc_wams/web-rtcp-5axis-xyzbc-trt-sim-plan/working/screenshots/estop-power-home-run-pause-50ms-20260707T141219Z
|
||||
captured_frames=459
|
||||
sample_period_ms=50
|
||||
manifest=/home/mes123456/cnc_wams/web-rtcp-5axis-xyzbc-trt-sim-plan/working/screenshots/estop-power-home-run-pause-50ms-20260707T141219Z/manifest.json
|
||||
```
|
||||
|
||||
manifest 暂停保持关键字段:
|
||||
|
||||
```text
|
||||
第一次暂停保持 5 秒:sampleIndex=109, activeLine=17, interpState=paused, taskPaused=true, motionPaused=true, currentVelocity=0
|
||||
第二次暂停保持 5 秒:sampleIndex=341, activeLine=13, interpState=paused, taskPaused=true, motionPaused=true, currentVelocity=0
|
||||
```
|
||||
|
||||
结论:
|
||||
|
||||
- 50ms 截图验证通过,两次暂停保持阶段 `sampleIndex`、`activeLine`、`interpState`、`taskPaused`、`motionPaused`、`currentVelocity` 均符合暂停冻结要求。
|
||||
|
||||
### 记录与关闭
|
||||
|
||||
对应任务:
|
||||
|
||||
- `W8-014`
|
||||
|
||||
结论:
|
||||
|
||||
- 本轮已更新 `03-推进台账.md`、`04-任务矩阵.md`、`05-验收证据.md`、`06-决策记录.md`。
|
||||
Reference in New Issue
Block a user