FOCAS: porting backlog from the stranded auto/driver-gaps branch (15 items, writes policy decision first, #607) #633

Closed
opened 2026-10-08 09:22:01 -04:00 by dohertj2 · 5 comments
Owner

Porting backlog for the FOCAS driver, from the #607 branch ledger (docs/plans/2026-10-08-driver-gaps-branch-ledger.md). These issues were auto-closed against PRs merged into auto/driver-gaps, which never reached master (and predates v3). Each item below was classified STRANDED: no equivalent on master (symbol/file grep plus docs), so the work needs a port-or-drop decision. The branch commit is listed per item (git show <sha> on origin/auto/driver-gaps); the branch is a design reference, not a cherry-pick, because the driver and the address-space model were rewritten since.

Policy decision first: master FOCAS is intentionally READ-ONLY (WireFocasClient.WriteAsync returns BadNotWritable, Wire/WireFocasClient.cs). #268-#271 (writes, wrmacro/wrparam, pmc_wrpmcrng, password/unlock) are safety-critical on real CNCs and need an explicit go/no-go before any port. Everything else needs the managed wire client (Wire/*), not the branch's FWLIB-style code, and CNC hardware or focas_mock to verify.

Source: #607; ledger rows for the original issue numbers below.

Port-or-drop checklist (15 items; effort S/M/L from the ledger):

  • #257 ODBST status flags as fixed-tree nodes (effort M; branch 551494d2). Master has Identity/Axes/Spindle/Program/OperationMode/Timers fixed tree only (docs/drivers/FOCAS.md:213); no ODBST status flags / Port risk: High: master FOCAS is a managed wire client rewrite (Wire/*); branch used FWLIB P/Invoke so must be re-done as wire commands; hardware-only to verify
  • #258 Parts count + cycle time (effort S; branch 3d9697b9). Timers/CycleSeconds present; parts count absent (partial) / Port risk: High: wire-client rewrite; needs cnc_rdparam/rdtimer decode on hardware
  • #259 Modal G/M/T codes + override values (effort M; branch 3c2c4f29). No modal/override reads / Port risk: High: wire-client rewrite
  • #260 Tool number / tool life + work coordinate offsets (effort L; branch 9ec92a90). No tooling/work-offset reads / Port risk: High: wire-client rewrite
  • #261 Operator messages + currently-executing block text (effort M; branch cc757855). No operator message / block text / Port risk: High: wire-client rewrite
  • #263 DIAG: address scheme (effort S; branch 451b37a6). No DIAG: address area (FocasAddress has PARAM/MACRO/PMC/FIXED only) / Port risk: High: wire rewrite
  • #264 Multi-path / multi-channel CNC (effort M; branch 2f3eeecd). No path-number / multi-path support found in FocasWireClient/options / Port risk: High: wire rewrite; hardware
  • #265 PMC F/G letters for 16i (effort S; branch 63099115). FocasCapabilityMatrix.cs:87 Sixteen_i PMC letters still {X,Y,R,D}; branch adds F,G (4-line change) / Port risk: Trivial, verify against 16i wire
  • #266 Bulk PMC range read coalescing (effort M; branch 4d3ee472). No PMC range coalescing (FocasPmcCoalescer); wire client has pmc_rdpmcrng primitive / Port risk: Medium: fits wire client
  • #267 cnc_rdalmhistry alarm-history extension (effort L; branch 7f9d6a77). No cnc_rdalmhistry; FocasAlarmProjection is polled cnc_rdalmmsg2 only / Port risk: High: wire rewrite + history decode
  • #268 Write infrastructure + per-tag opt-in (effort M; branch 1bfe8fba). Master FOCAS is intentionally READ-ONLY: WireFocasClient.WriteAsync returns BadNotWritable (Wire/WireFocasClient.cs:13-15,73) / Port risk: High: safety-critical on real CNCs; policy decision needed before any port
  • #269 cnc_wrmacro + cnc_wrparam (effort M; branch f48f31cf). wrmacro/wrparam deliberately not exposed in wire client / Port risk: High: as #268
  • #270 pmc_wrpmcrng (effort M; branch 54c09d4d). pmc_wrpmcrng not exposed; PMC bit-RMW absent despite stale comment in FocasDriverOptions / Port risk: High: as #268
  • #271 Password / unlock parameter (effort M; branch 86f3fc27). No password/unlock / Port risk: High: as #268
  • #272 Cycle time per part / last cycle delta (effort S; branch e3d7c65f). No per-part cycle delta / Port risk: Depends on #258

Filed 2026-10-08 by the hardware-available issue sweep.

Porting backlog for the FOCAS driver, from the #607 branch ledger (`docs/plans/2026-10-08-driver-gaps-branch-ledger.md`). These issues were auto-closed against PRs merged into `auto/driver-gaps`, which never reached master (and predates v3). Each item below was classified STRANDED: no equivalent on master (symbol/file grep plus docs), so the work needs a port-or-drop decision. The branch commit is listed per item (`git show <sha>` on `origin/auto/driver-gaps`); the branch is a design reference, not a cherry-pick, because the driver and the address-space model were rewritten since. **Policy decision first:** master FOCAS is intentionally READ-ONLY (`WireFocasClient.WriteAsync` returns BadNotWritable, `Wire/WireFocasClient.cs`). #268-#271 (writes, wrmacro/wrparam, pmc_wrpmcrng, password/unlock) are safety-critical on real CNCs and need an explicit go/no-go before any port. Everything else needs the managed wire client (`Wire/*`), not the branch's FWLIB-style code, and CNC hardware or `focas_mock` to verify. Source: #607; ledger rows for the original issue numbers below. Port-or-drop checklist (15 items; effort S/M/L from the ledger): - [ ] #257 ODBST status flags as fixed-tree nodes (effort M; branch 551494d2). Master has Identity/Axes/Spindle/Program/OperationMode/Timers fixed tree only (docs/drivers/FOCAS.md:213); no ODBST status flags / Port risk: High: master FOCAS is a managed wire client rewrite (Wire/*); branch used FWLIB P/Invoke so must be re-done as wire commands; hardware-only to verify - [ ] #258 Parts count + cycle time (effort S; branch 3d9697b9). Timers/CycleSeconds present; parts count absent (partial) / Port risk: High: wire-client rewrite; needs cnc_rdparam/rdtimer decode on hardware - [ ] #259 Modal G/M/T codes + override values (effort M; branch 3c2c4f29). No modal/override reads / Port risk: High: wire-client rewrite - [ ] #260 Tool number / tool life + work coordinate offsets (effort L; branch 9ec92a90). No tooling/work-offset reads / Port risk: High: wire-client rewrite - [ ] #261 Operator messages + currently-executing block text (effort M; branch cc757855). No operator message / block text / Port risk: High: wire-client rewrite - [ ] #263 DIAG: address scheme (effort S; branch 451b37a6). No DIAG: address area (FocasAddress has PARAM/MACRO/PMC/FIXED only) / Port risk: High: wire rewrite - [ ] #264 Multi-path / multi-channel CNC (effort M; branch 2f3eeecd). No path-number / multi-path support found in FocasWireClient/options / Port risk: High: wire rewrite; hardware - [ ] #265 PMC F/G letters for 16i (effort S; branch 63099115). FocasCapabilityMatrix.cs:87 Sixteen_i PMC letters still {X,Y,R,D}; branch adds F,G (4-line change) / Port risk: Trivial, verify against 16i wire - [ ] #266 Bulk PMC range read coalescing (effort M; branch 4d3ee472). No PMC range coalescing (FocasPmcCoalescer); wire client has pmc_rdpmcrng primitive / Port risk: Medium: fits wire client - [ ] #267 cnc_rdalmhistry alarm-history extension (effort L; branch 7f9d6a77). No cnc_rdalmhistry; FocasAlarmProjection is polled cnc_rdalmmsg2 only / Port risk: High: wire rewrite + history decode - [ ] #268 Write infrastructure + per-tag opt-in (effort M; branch 1bfe8fba). Master FOCAS is intentionally READ-ONLY: WireFocasClient.WriteAsync returns BadNotWritable (Wire/WireFocasClient.cs:13-15,73) / Port risk: High: safety-critical on real CNCs; policy decision needed before any port - [ ] #269 cnc_wrmacro + cnc_wrparam (effort M; branch f48f31cf). wrmacro/wrparam deliberately not exposed in wire client / Port risk: High: as #268 - [ ] #270 pmc_wrpmcrng (effort M; branch 54c09d4d). pmc_wrpmcrng not exposed; PMC bit-RMW absent despite stale comment in FocasDriverOptions / Port risk: High: as #268 - [ ] #271 Password / unlock parameter (effort M; branch 86f3fc27). No password/unlock / Port risk: High: as #268 - [ ] #272 Cycle time per part / last cycle delta (effort S; branch e3d7c65f). No per-part cycle delta / Port risk: Depends on #258 *Filed 2026-10-08 by the hardware-available issue sweep.*
Author
Owner

Per-item status (merge 7a9b51ae b626-ablegacy-focas):

Per-item status (merge 7a9b51ae b626-ablegacy-focas): - Ported: #265 - Won't port (FOCAS is read-only by policy): #268 #269 #270 #271 - Hardware-deferred: #257-#264, #266, #267, #272 Left open for the user to decide closure.
Author
Owner

Landed in b640 (FOCAS merge 216dc63a + c86204b7): #257 Status/ nodes, #266 PMC read coalescing, #258 parts-count docs; live against focas-sim: new tests pass. Remaining: #259 #260 #261 #263 #264 #267 #272 need wire captures, hardware or design. New: FOCAS native alarms are unroutable -> #647; stale focas-sim fixture image -> #651. Leaving open.

Landed in b640 (FOCAS merge 216dc63a + c86204b7): #257 Status/ nodes, #266 PMC read coalescing, #258 parts-count docs; live against focas-sim: new tests pass. Remaining: #259 #260 #261 #263 #264 #267 #272 need wire captures, hardware or design. New: FOCAS native alarms are unroutable -> #647; stale focas-sim fixture image -> #651. Leaving open.
Author
Owner

Progress from batch b647 (pushed e7dd7425): #268–#271 recorded as won't-do (FOCAS read-only policy) in docs/drivers/FOCAS.md 'Not ported'; #258 parts count now recommends MACRO:3901 (the Makino refuses PARAM:6711 with EW_FUNC); #259 overrides documented as a read-only PMC recipe (G12 / G14.0-1 / G30); #272 replaced by a virtual-tag recipe; #265 was already on master. Still open: read-only Makino confirmation of #257 / #266 / #258, and the blocked items (modal codes, offsets, operator messages, DIAG:, alarm history, multi-path), which need FOCAS command IDs captured from a non-production control — never probed on the Makino.

Progress from batch b647 (pushed `e7dd7425`): #268–#271 recorded as **won't-do** (FOCAS read-only policy) in docs/drivers/FOCAS.md 'Not ported'; #258 parts count now recommends `MACRO:3901` (the Makino refuses PARAM:6711 with EW_FUNC); #259 overrides documented as a read-only PMC recipe (G12 / G14.0-1 / G30); #272 replaced by a virtual-tag recipe; #265 was already on master. Still open: read-only Makino confirmation of #257 / #266 / #258, and the blocked items (modal codes, offsets, operator messages, DIAG:, alarm history, multi-path), which need FOCAS command IDs captured from a non-production control — never probed on the Makino.
Author
Owner

Read-only live checks on Makino Z-34184 (master ec375538), FOCAS read calls only, one session, ≥ 2 s polling:

  • #257 Status/ flags decode steadily: Auto=3 Run=0 (RESET), no E-stop, Alarm=0 (the triage's "permanent alarm=4" is not true today). Open question for someone at the panel: Auto=3 is EDIT in the documented table, but the separate operating-mode read reported AUTO throughout.
  • #258 MACRO:3901 / 3902 read 0.0 at Good.
  • #266 coalescing: 12 per-tag PMC reads became 4 pmc_rdpmcrng ranges, identical values.
  • #259 overrides: G12 = -101, G14 bits off, G30 = 100 — consistent with all overrides at 100 %. The docs recipe was wrong (a PMC Byte tag is signed, so 255 - v gave 356); corrected to mask the byte, and noted that 128–150 % spindle overrides read negative.

Observed, not changed: the block-count read is refused (rc=-7) and re-sent on every program poll (82× in 4 min); the fixed-tree default 250 ms poll is ~28 req/s on this 7-axis control — worth checking the production setting.

Remaining items still need a non-production control (command-id capture).

Read-only live checks on Makino Z-34184 (master `ec375538`), FOCAS read calls only, one session, ≥ 2 s polling: - #257 `Status/` flags decode steadily: `Auto=3 Run=0 (RESET)`, no E-stop, `Alarm=0` (the triage's "permanent alarm=4" is not true today). Open question for someone at the panel: `Auto=3` is EDIT in the documented table, but the separate operating-mode read reported AUTO throughout. - #258 `MACRO:3901` / `3902` read 0.0 at Good. - #266 coalescing: 12 per-tag PMC reads became 4 `pmc_rdpmcrng` ranges, identical values. - #259 overrides: G12 = -101, G14 bits off, G30 = 100 — consistent with all overrides at 100 %. The docs recipe was wrong (a PMC Byte tag is signed, so `255 - v` gave 356); corrected to mask the byte, and noted that 128–150 % spindle overrides read negative. Observed, not changed: the block-count read is refused (rc=-7) and re-sent on every program poll (82× in 4 min); the fixed-tree default 250 ms poll is ~28 req/s on this 7-axis control — worth checking the production setting. Remaining items still need a non-production control (command-id capture).
Author
Owner

Closing: every item that can be checked read-only on the Makino is done (see previous comment). The remaining items need command-id capture on a non-production control and stay out of scope under the FOCAS read-only policy; refile individually if such a control becomes available.

Closing: every item that can be checked read-only on the Makino is done (see previous comment). The remaining items need command-id capture on a non-production control and stay out of scope under the FOCAS read-only policy; refile individually if such a control becomes available.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: dohertj2/lmxopcua#633