Files
cnc_wams/完善wasm/working/35-三解释器同步-Wrapped-Rotary-角轴限速Gate实施记录.md
2026-07-10 21:26:42 -04:00

61 lines
2.9 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# 三解释器同步、Wrapped Rotary 与角轴限速 Gate 实施记录
## 目标
本文件落实 `ACC-047/INT-034`,闭合 04 多 session 中仍缺专项 proof 的 5.1、5.3、5.5,并补强 8.3 `WRAPPED_ROTARY` 与 8.10 旋转轴进给率数值证据。
## 三解释器隔离与同步
新增 `verify_three_session_interp_sync_evidence.mjs`,并发创建三个独立 LinuxCNC interpreter WASM module。每个实例只运行 LinuxCNC-owned 程序语义:
| Session | G5x | G10 rotation | M62 sync output |
| --- | --- | --- | --- |
| alpha | G55/P2 | 10° | P1 |
| beta | G56/P3 | 20° | P2 |
| gamma | G57/P4 | 30° | P3 |
gate 验证每个实例输出自己的 `SET_G5X_OFFSET``SET_XY_ROTATION``SET_MOTION_OUTPUT_BIT`,且其他 session 的 rotation 不会泄漏。上层编排只在匹配指定 M62 canonical output 时释放对应依赖,不静默执行 M100-M199 宿主程序。
## Wrapped Rotary
将上游 `configs/sim/axis/wrapped_rotary/wrapped_rotary.ini` 加入 source manifest 并抽取到 vendor。扩展 `parseLinuxCncIni()`,将 `AXIS_* WRAPPED_ROTARY` 解析为 `axisLimits.<axis>.wrappedRotary`gate 断言坐标为 `X Y Z A` 且 A 轴 `wrappedRotary=true`
04 的 8.3 已从与实际配置不一致的“C 轴/xyzab.ini”改为该上游配置真实证明的“A 轴回卷旋转”。
## G93 角轴限速
叶轮 gate 初次增加数值断言时发现G93 inverse-time 请求峰值约 `319782.84 deg/min`XYZAC INI 最大角速度为 `1800 deg/min`,原 `execution-timing.js` 会让请求块时长无条件覆盖角轴限速。
修复后每段时长取以下三者最大值:
```text
inverse-time requested seconds
linear-axis limit seconds
angular-axis limit seconds
```
实际角速度由最终时长反算并限制在 INI 上限内。叶轮 4066 个旋转进给段中有 6 个被机床约束延长,最终最大角速度为 `1800 deg/min`,等于 INI 上限;请求速度另存为 `requestedAngularVelocityDegPerMin`,不丢失诊断信息。
## 验证输出
```text
three_session_interpreter_instances=ok
three_session_g5x_rotation_isolation=ok
three_session_canonical_sync_orchestration=ok
wrapped_rotary_ini_semantics=ok
impeller_rotary_feed_segments=4066
impeller_constraint_limited_rotary_segments=6
impeller_max_requested_angular_velocity_deg_per_min=319782.8381987813
impeller_max_angular_velocity_deg_per_min=1800
impeller_ini_angular_velocity_limit_deg_per_min=1800
impeller_feed_task_hal_run=ok
```
## 边界
三 session 是三个独立 Web/WASM interpreter instance不是单 LinuxCNC task 内建多通道。M62 canonical output 证明受控上层编排输入,不代表宿主 User-M process 已运行。timing 层仍是 canonical motion + INI constraint estimate不冒充完整 native planner queue。
## 结论
`ACC-047/INT-034` 完成。5.1、5.3、5.5、8.3、8.10 均已有可重复的 source-owned 或 source-derived专项 gate剩余边界不再包含这些软件证据缺口。