Align Web execute-next-line with LinuxCNC

This commit is contained in:
2026-09-10 08:30:04 +08:00
parent 0a202e5841
commit aac1ceb250
5 changed files with 226 additions and 17 deletions

View File

@@ -395,8 +395,9 @@ export function App() {
setOperationTrace(operationController.exportTrace()); setCommandStatus(`${kind} acknowledged`);
if (kind === "PROGRAM_RUN" || kind === "PROGRAM_RESUME") startRunTimer();
if (["PROGRAM_PAUSE", "PROGRAM_ABORT", "PROGRAM_RESTART"].includes(kind)) stopRunTimer();
const result = (operation.response as { payload?: { homing?: { phase?: string }; panel_snapshot?: { motion?: { homing?: boolean } } } }).payload;
const result = (operation.response as { payload?: { homing?: { phase?: string }; step_waiting_for_motion?: boolean; panel_snapshot?: { motion?: { homing?: boolean } } } }).payload;
if (kind === "HOME" && result?.homing?.phase === "accepted") startHomeTimer();
if (kind === "PROGRAM_STEP" && result?.step_waiting_for_motion === true) startRunTimer();
// Ordinary abort keeps sampling the native free_tp deceleration.
if (kind === "PROGRAM_ABORT") { if (result?.panel_snapshot?.motion?.homing) startHomeTimer(); else stopHomeTimer(); }
if (["ESTOP", "POWER"].includes(kind)) stopHomeTimer();