Architecture decisions¶
arc42 §9 — the accepted decisions behind the EtherCAT network-config
codegen toolchain (EtherCAT network-config cod... (FEAT_0080)). Each arch-decision
:refines: the parent requirement or feature it serves.
Context. “Configure the EtherCAT network with a YAML file” admits
two architectures: parse the YAML at startup into owned, heap-allocated
config, or compile it at build time into the Decision. The YAML is resolved at build time. A Consequences. Allocation is known at init, the |
Context. A device on an EtherCAT bus can be named three ways: by
configured station address ( Decision. The YAML declares devices in bus order; codegen
assigns the configured address as Consequences. Integrators never hand-type |
Context. A device entry may reference a vendor ESI file by local
path or web URL. A live web fetch inside Decision. The build resolves ESI references from local files
only. A web URL is an input to a deliberate Consequences. Builds stay hermetic, reproducible, and
air-gappable, mirroring how |
Context. Decision. Consequences. One source of truth; the value cannot drift from the
mapping that produced it. A bus whose real working counter diverges
from the derived expectation is caught at runtime via the existing
|
Context. A config could describe one bus or many. Each bus maps to
one connector, one NIC, and one process image, and carries its own
compile-time const-generic bounds ( Decision. One Consequences. The schema and the const-generic bounds stay simple and per-bus, matching the one-NIC-per-example reality. The cost is that a large multi-bus installation maintains several files — accepted for v1, revisited if a real multi-bus need appears. |