Ryan Malloy accec686f8 Prove the 45-degree win: 29% shorter, DRC-clean, exact clearance load-bearing
Add diagonal_win.dsn: a 45-degree pin-to-pin net with a keepout placed inside the
diagonal's bounding box but clear of the true thin copper. Orthogonal routing
connects it with a Manhattan-length staircase (1600000); diagonal routing
replaces that with a single 45-degree trace at the ideal hypotenuse length
(1131371) -- a 29% reduction -- DRC-clean via the search tree and via an
independent reconstruction of the emitted 45-degree copper's clearance octagon.

test_exact_clearance_is_load_bearing shows the keepout overlaps the coarse
bounding box but not the exact octagon, so the exact clearance (not the box) is
what lets the diagonal route. Determinism, endpoints-on-pads, valid SES, and
diagonal-off-equals-orthogonal (additive, over four fixtures) are covered.
2026-07-13 12:57:13 -06:00
..

DSN test fixtures

Hand-crafted minimal Specctra DSN files, written to exercise the parser. They are modeled on the real fixtures shipped in the upstream FreeRouting repo (fixtures/empty_board.dsn and fixtures/SMD-routing-issue-demo.dsn) so the grammar and formatting match what kicad-cli pcb export specctra-dsn and FreeRouting itself produce, but they were typed fresh here (no upstream file is copied into this tree).

  • empty_board.dsn — the smallest valid board: parser, resolution, unit, and a structure with two signal layers and a pcb boundary path. Modeled on FreeRouting fixtures/empty_board.dsn.
  • smd_demo.dsn — a fuller board exercising every scope the parser handles: quoted board/padstack/image names, via, default rule (width + clearance with a (type smd_smd) pair), a keepout, padstacks (rect and circle pads), images with pins, placement with front/rotation, nets with Comp-Pin references, and a class with circuit/use_via and a rule. Modeled on FreeRouting fixtures/SMD-routing-issue-demo.dsn.