abse/gameboy-advance

A tscircuit package created by abse.

Version
0.0.45
License
unset
Stars
0

checks/FABRICATION-ORIENTATION.md

PCBPCB preview for checks/FABRICATION-ORIENTATION.md
SchematicSchematic preview for checks/FABRICATION-ORIENTATION.md
# JLCPCB placement orientation

The custom native build created `Circuit` without a parts engine, so its output lacked supplier reference orientations. Strict fabrication export correctly refused to guess the JLCPCB rotation.

The build now runs the standard `populatePartOrientationMetadata` using frozen, actual JLCPCB/EasyEDA reference circuits in `supplier-orientation`. This is a deterministic offline parts-engine adapter. Provenance records SHA-256 hashes. It does not substitute the authored rotation for missing reference data.

Three connectors require explicit interpretation of the reference frame: USB uses a documented legacy-to-supplier pin mapping; the LCD and power switch have mounting pads outside the electrical contact row. Each of these is checked against every supplier pad center at build time, allowing only a unique rigid 0/90/180/270-degree fit with at most 0.02 mm error. No pad or route geometry is modified.

`fabrication-orientation.ts` runs strict JLCPCB CSV generation with `requireSupplierRotation: true`. Missing, incompatible, or mismatched data fails the build. The resulting report and CSV are under `dist/index`.

Verification: `npm run build`, `npm run check:fabrication`, and `tsci export dist/index/circuit.json -f gerbers`. The last produces Gerbers, drills, BOM and pick-and-place CSV. The CSV must agree with the strict supplier-aware output.

All authored frames are recomputed from numbered copper pads, undoing bottom-side mirroring before undoing rotation, matching core’s placement transform. This resolves the bottom-side USB LED’s ambiguous explicit two-pad frame without moving or renumbering its pads.