Files
STM32F4-Base/test/host/ioboard
wandering1 6e0755f971 feat(ioboard): make KO_24V an auto relay supply enable (9 channels)
KO_24V (PF4, bit6) is not an externally controllable output: it feeds
the other KO channels, so the driver now asserts it automatically
whenever any relay-class channel (bit0/1/2/3/7/8) is attracted, and
never for the three LED channels (bit4/5/9). Externally controllable
outputs become 9; physical bit map, DO_COUNT=10, DO_MASK_ALL=0x03FF,
k_do_pin[] binding, per-port BSRR segments and the uint16_t path are
unchanged.

- ioboard_do_write: clear the caller's bit6, synthesize it from
  IOBOARD_DO_RELAY_MASK (0x18F), then one shadow store + one apply,
  so bit6 changes in the same BSRR write as its GPIOF neighbours.
- ioboard_do_get: bit6 now reports the actual 24V supply state, not
  an echo of the caller's write. Power-on release keeps PF4 low.
- board test Phase 3 derives expectations from RELAY_MASK (no second
  truth table); the KO_24V row exercises "write ignored" and a new
  auto-24V check verifies set-on-relay / drop-on-release.
- host contract test pins RELAY_MASK membership (excludes bit6 and
  LED bits, union fills 0x3FF); 131/131 passed.
- docs: sync note v1.4 + BSP README unify the semantics (9
  controllable + auto supply enable); stale "10 controllable" and
  "24V interlock not implemented" wording removed; netlist-unknown
  routing, PC15 backup-domain 3 mA limit and the missing auxiliary
  contact remain documented as open facts.

Verified: Keil rebuild 0 error 0 warning (sizes identical to parent
wave), host unit tests 131/131, check_bsp_err / check_doc_links /
git diff --check clean. Board Phase 3 still needs a bench run.
2026-11-18 19:34:47 +08:00
..