Skip to the content
2 layers60 × 50 mmTest board, the printed circuit board in 3D

Test board

Bu3nd14/EDA

Scripted analog EDA + PCB automation environment (KiCad 10 + ngspice + SKiDL) for macOS Apple Silicon

Size
60 × 50 mm
Copper layers
2
Thickness
1.6 mm
Parts
2
Nets
2
Pads
4
Tracks, vias
1, 1
Pours
1
Routed
Yes
KiCad
KiCad 10.0 (file 20260206)
Created
7 Sep 2026
Updated
5 Nov 2026

Overview

Test board is an open-source printed circuit board by Bu3nd14, from the Bu3nd14/EDA repository on GitHub. It is a 2-layer board of 60 × 50 mm with 2 parts on 2 nets, routed with 1 track and 1 via.

Its parts include 1 capacitor and 1 resistor.

README

README.md

EDA — Analog EDA + PCB Automation Environment

A scripted, non-interactive toolchain for taking an analog circuit from code-first topology definition through SPICE simulation, KiCad schematic generation, PCB layout, autorouting, DRC/ERC, and fabrication export — on macOS / Apple Silicon.

This README documents only what has been verified by actually running commands in this environment. See docs/limitations.md for the full limitations list and docs/smoke-test.md for the end-to-end pipeline evidence.

Installed tools

ToolVersionPathNotes
ngspice47/opt/homebrew/bin/ngspiceNative arm64 (file → "Mach-O 64-bit executable arm64", non-fat). Installed via brew install ngspice.
KiCad10.0.6App: /Users/roberto/Applications/KiCad.app; CLI: /Users/roberto/Applications/KiCad.app/Contents/MacOS/kicad-cliUniversal binary (x86_64 + arm64), runs natively on Apple Silicon. Installed from the official CERN-hosted dmg into ~/Applications, without sudo.
Python (project)3.13.15/opt/homebrew/bin/python3.13Native arm64. Project venv at /Users/roberto/EDA/env/venv.
SKiDL2.3.0installed in env/venvCode-first circuit definition layer.
Python (KiCad bundled)3.9.13/Users/roberto/Applications/KiCad.app/Contents/Frameworks/Python.framework/Versions/3.9/bin/python3.9The only interpreter where import pcbnew works. pcbnew is not pip-installable.
kinet2pcb(per bundled install)installed into the bundled python3.9 via --user pip installNot installed in the venv.
Freerouting2.4.1/Users/roberto/EDA/scripts/tools/freerouting.jarExternal autorouter. Needs a JRE (brew install openjdk).
poppler (pdftotext)26.09.0/opt/homebrew/bin/pdftotextNative arm64 (file → "Mach-O 64-bit executable arm64"). Installed via brew install poppler in L6. Reads vendor datasheet PDFs past page 1, which sips/qlmanage cannot. No script requires it, so verify_env.sh does not check for it: scripts/pdf_glyphs.py is the stdlib-only fallback.

Installation procedure (as actually done)

  1. ngspice: brew install ngspice.
  2. KiCad 10.0.6: download the official dmg from kicad.org and install into ~/Applications without sudo.
    • Pitfall (verified failure): the Homebrew cask (brew install --cask kicad) FAILS during install because its bundled demos artifact needs sudo to write to /Library/Application Support/kicad. Use the no-sudo dmg route instead — do not retry the brew cask expecting a different result.
  3. Python / venv: python3.13 -m venv /Users/roberto/EDA/env/venv, then pip install skidl (→ SKiDL 2.3.0) inside that venv.
  4. kinet2pcb: installed into KiCad's bundled python3.9, not the venv:
    text
    /Users/roberto/Applications/KiCad.app/Contents/Frameworks/Python.framework/Versions/3.9/bin/python3.9 -m pip install --user kinet2pcb
  5. Freerouting: freerouting.jar placed at scripts/tools/freerouting.jar. Requires a JRE: brew install openjdk, then invoke with PATH="/opt/homebrew/opt/openjdk/bin:$PATH" java -jar scripts/tools/freerouting.jar ....
  6. poppler: brew install poppler (added in L6). Only needed to read vendor datasheet PDFs beyond the first page — macOS ships sips and qlmanage, which render page 1 only. No script in this repo depends on it; scripts/pdf_glyphs.py covers the text case with the stdlib alone.

Architecture: selected stack and rejected alternatives

Selected: KiCad 10 + ngspice, with SKiDL as the code-first circuit definition layer and Freerouting as an external autorouter.

AlternativeRejected because
LibrePCBNo SPICE export at all — structurally incompatible with a simulate-then-layout workflow. SKiDL also has no LibrePCB output path.
Qucs-SNo headless/CLI mode found. Usable only as an optional human-facing GUI visualization layer, not automation.
gEDA/gafEffectively dead (~1-2 commits/year, last stable release 2020).
XyceKept only as a possible alternate SPICE backend. ngspice is the reference engine KiCad targets and has a faster release cadence.

Source-of-truth strategy

A hybrid model with a hard boundary:

  • Circuit topology (parts, values, connections) is canonical in Python/SKiDL, intended to live under circuits/*.py (version-controlled, no GUI state). TODO: unverified — a circuits/ directory does not yet exist in this repo; the only SKiDL topology definition currently present is the smoke-test fixture at smoke/rc_circuit.py.
  • Physical layout (placement, routing, stackup) is canonical in the .kicad_pcb file, because layout cannot be expressed in SKiDL.
  • The netlist is a one-way sync contract: code → KiCad. Never hand-edit the generated schematic/netlist and expect it to survive regeneration. Never treat the .kicad_pcb as a topology source.
  • Correction to the naive "SKiDL → SPICE" assumption: the SPICE netlist used for simulation is derived from the generated schematic via kicad-cli sch export netlist --format spice, not from SKiDL's native SPICE generator. SKiDL's native SPICE path does not work with KiCad-library parts — see Limitations #2.

Project structure

text
EDA/
  models/         curated, canonical SPICE models (.include-able), each with a
                  <file>.provenance.json sidecar. See models/README.md,
                  models/PROVENANCE_CONVENTION.md.
  vendor/         read-only vendor originals (mode 0444, sha256 + PROVENANCE.json
                  per part). Never hand-edited. See vendor/README.md.
  scripts/        automation entry points (setup, validation, simulation, ERC/DRC,
                  fab export) and support tools (freerouting.jar). Owned/maintained
                  separately — see "Scripts" below.
  testbenches/    standalone ngspice .cir testbenches (01_op .. 08_vendor_model)
                  used to exercise/validate analysis types and the model library.
  smoke/          scratch: the trivial RC-lowpass smoke-test fixture and its
                  full pipeline output (schematic, netlists, sim results, PCB,
                  routing, DRC/ERC reports, gerbers).
  pcb/            scratch: PCB-automation-engineer's capability tests
                  (board creation, DSN/SES routing round-trip, DRC, fab export).
  results/        scratch: simulation outputs (raw + normalized CSV/JSON) and
                  model-validation testbenches/results.
  docs/           this documentation set (architecture, limitations, smoke-test
                  report).
  env/venv/       project Python 3.13 virtualenv (SKiDL).
  .claude/agents/ subagent role definitions (see AGENTS.md).

circuits/ (canonical topology home per the source-of-truth strategy) does not exist yet — TODO: unverified, flagged rather than assumed.

smoke/ and results/ are scratch, not canonical; models/, vendor/ are canonical (see AGENTS.md operating rules).

Simulation workflow

All ngspice runs are non-interactive (ngspice -b). Verified analysis types, with existing testbenches under testbenches/:

TestbenchAnalysis
01_op.cir.op
02_dc.cir.dc sweep
03_ac.cir.ac
04_tran.cir.tran
05_noise.cir.noise
06_paramsweep.cirparameter sweep (via .control/alterparam, not native .step — see Limitations #10)
07_temp.cirtemperature sweep
08_vendor_model.cirvendor-model .include

Run directly, e.g.:

text
/opt/homebrew/bin/ngspice -b /Users/roberto/EDA/testbenches/04_tran.cir

Results are written via wrdata/.print/.write and normalized to CSV/JSON with scripts/normalize_wrdata.py (present under results/*.normalized.{csv,json}).

Accuracy: verified against closed-form theory (RC -3dB point, RC time constant, thermal noise floor) to well under 1% error. Example from the smoke-test RC fixture (R=1k, C=100n): theoretical fc = 1591.55 Hz, simulated fc = 1587.62 Hz, error 0.25%.

Model library: models/ contains curated device models (resistor, capacitor, inductor, diode, BJT NPN/PNP, MOSFET N/P, JFET, opamp macro-model, generic transformer subckt), each validated by scripts/validate_models.py against a real ngspice testbench (38/38 checks passing at last verification). The R/C/L/transformer/opamp checks are exact analytic cross-checks; the BJT/MOSFET/JFET checks are order-of-magnitude sanity checks only, not exact — see Limitations #11. The validator was proven to catch both a bad model parameter and a tampered vendor file (exit 1 in both cases).

Vendor model provenance: vendor/ holds read-only (mode 0444) originals with sha256 + PROVENANCE.json; models/ holds curated/derived copies, each with a .provenance.json sidecar recording origin and any changes. See models/PROVENANCE_CONVENTION.md.

PCB workflow

Verified capabilities, driven through the pcbnew Python API (bundled python3.9) and kicad-cli:

  • Board creation; footprint load/place from KiCad standard libraries; footprint inspection; move/rotate with verified persistence; geometry/ courtyard queries; net enumeration and assignment; track and via creation; copper zone creation with real fill; save/reload round-trip fidelity.
  • ERC: kicad-cli sch erc --format json --exit-code-violations — real JSON output, correct exit codes.
  • DRC: kicad-cli pcb drc --format json --exit-code-violations — real JSON, exit 5 on violations / 0 when clean. Verified semantically correct: flagged genuine unconnected items before routing, clean after.
  • Fabrication export: kicad-cli pcb export gerbers and kicad-cli pcb export drill — verified by inspecting file contents (valid RS-274X and Excellon data), not just exit codes.
  • Routing: KiCad itself has no built-in autorouter. Routing is done via an external round-trip: pcbnew.ExportSpecctraDSN → Freerouting CLI → pcbnew.ImportSpecctraSES → DRC clean (0 violations), verified end-to-end. Note kicad-cli does not offer DSN export — only the pcbnew Python API does.

Example Freerouting invocation (from smoke/run_pipeline.sh):

text
PATH="/opt/homebrew/opt/openjdk/bin:$PATH" java -jar /Users/roberto/EDA/scripts/tools/freerouting.jar \
  -de rc_circuit.dsn -do rc_circuit.ses -mp 1 -l en

GUI-only KiCad features (e.g. the interactive router) were not tested and must not be assumed scriptable (Limitations #12).

API/automation workflow: the two-interpreter bridge

SKiDL runs on the project venv, Python 3.13 (/Users/roberto/EDA/env/venv/bin/python3). pcbnew and kinet2pcb run only on KiCad's bundled Python 3.9 (/Users/roberto/Applications/KiCad.app/Contents/Frameworks/Python.framework/Versions/3.9/bin/python3.9). Any script that touches both must bridge explicitly with absolute interpreter paths — invoking each stage with its own interpreter, e.g. from smoke/run_pipeline.sh:

sh
SKIDL_PY=/Users/roberto/EDA/env/venv/bin/python3
KICAD_PY=/Users/roberto/Applications/KiCad.app/Contents/Frameworks/Python.framework/Versions/3.9/bin/python3.9

venv/bin/python -c "import pcbnew" fails with ModuleNotFoundError — this is not a configuration bug, it is the expected split. Never assume one interpreter can do both halves of the pipeline.

Scripts

Scripts live under scripts/ (owned/maintained by a separate workflow — see AGENTS.md). Confirmed present at time of writing: scripts/validate_models.py, scripts/freeze_vendor.sh, scripts/normalize_wrdata.py, scripts/pcbnew_test.py, scripts/specctra_roundtrip_test.py, scripts/tools/freerouting.jar.

The following entry points are documented interface (purpose/invocation as specified) — they were being written/verified concurrently with this documentation, so their internals are not described here beyond intent:

ScriptPurpose
scripts/setup.shOne-shot environment setup.
scripts/verify_env.shVerify installed tool versions/paths match what's documented.
scripts/run_simulation.sh <netlist.cir> [outdir]Run an ngspice batch simulation and extract results.
scripts/run_tests.shRun the project's test/validation suite.
scripts/validate_models.pyValidate every model in models/ against a real ngspice testbench; also checks provenance (--check-provenance).
scripts/run_erc.sh <sch> [outjson]Run kicad-cli sch erc and emit JSON.
scripts/run_drc.sh <pcb> [outjson]Run kicad-cli pcb drc and emit JSON.
scripts/export_fab.sh <pcb> [outdir]Export gerbers/drill; refuses to export if DRC fails.
scripts/check_schematic.py <manifest.json> <netlist.cir>Verify a hand-laid-out schematic drawing against the netlist, in both directions. Exit 1 on any mismatch.
scripts/pdf_glyphs.py <file.pdf> [--offset N|--scan|--raw]Extract text from a PDF with the stdlib only (zlib + the text operators). The mechanical half of the two-independent-readings rule ADR-013 imposes on hand-transcribed vendor models. Not a general-purpose extractor — see its header.
scripts/freeze_vendor.shSet every file under vendor/ to mode 0444. Idempotent.

TODO: unverified — confirm the final invocation syntax/flags of the above against the actual script contents once they land; this table reflects the interface as specified to this documentation task, not a read of the scripts themselves (except validate_models.py, which already exists and is described above from models/README.md).

Human-reviewable schematics

Readable analog schematics cannot be auto-placed — researched and tested against ASG, lcapy and netlistsvg, none of which work for this (see docs/limitations.md #16). Every tool that does automatic placement targets digital netlists, where dataflow dictates layout; analog readability lives in conventions that encode designer intent and are absent from the netlist.

Drawings are therefore laid out by hand, in code, with schemdraw — a text source that versions and diffs. The resulting risk, a drawing drifting silently from the circuit, is mechanised away: each drawing emits a connectivity manifest next to its SVG, and scripts/check_schematic.py compares it to the netlist in both directions (nothing invented, nothing omitted). scripts/run_tests.sh discovers every manifest under docs/*/schematic/ automatically.

The checker was proven to catch an invented device, an omitted device and a miswired pin — it passes a correct manifest and fails a deliberately broken one.

A human-reviewable schematic is a precondition for gates G1 and G2. See docs/architecture.md for the convention and AGENTS.md for the gate rule.

Limitations

Full detail in docs/limitations.md. Summary (none of these are soft-pedaled):

  1. Two-interpreter split (SKiDL venv 3.13 vs KiCad bundled 3.9) — must bridge with absolute paths.
  2. SKiDL's native SPICE path does not work with KiCad-library parts; the schematic→kicad-cli sch export netlist --format spice path is used instead.
  3. SKiDL drops Sim.Type/Sim.Device when caching symbols into the generated .kicad_sch — silent invalid SPICE line unless set manually.
  4. SKiDL-generated schematics fail real KiCad ERC (power_pin_not_driven on GND + 3 lib_symbol_mismatch warnings).
  5. SKiDL's schematic auto-placement is visually unusable (machine-valid, not human-presentable).
  6. SKiDL needs version-numbered env vars (KICAD10_SYMBOL_DIR/KICAD10_FOOTPRINT_DIR for SKiDL 2.3.0); wrong version → confusing FileNotFoundError.
  7. SKiDL treats a missing footprint as a hard error even for simulation-only symbols.
  8. item.GetLayerName() in pcbnew is unreliable — use board.GetLayerName(item.GetLayer()) or IsOnLayer().
  9. ImportSpecctraSES gives no error message on failure — only True/False.
  10. ngspice gotchas: no native .step (use .control/alterparam); multi-value .temp silently falls back to 27°C with only a warning (use dc TEMP start stop step inside .control); .lib <file> fails for plain model files (use .include); C/L need C=/inductance=, not a positional value; the first line of any .cir is always a title/comment.
  11. BJT/MOSFET/JFET model checks in validate_models.py are order-of-magnitude sanity checks, not exact analytic cross-checks like R/C/L/transformer/opamp.
  12. GUI-only KiCad features (e.g. interactive router) were not tested and must not be claimed as scriptable.

Smoke test results

Trivial RC low-pass fixture (R=1k, C=100n), driven through the full pipeline by smoke/run_pipeline.sh. 11 stages PASSED, 3 PARTIAL, 0 FAILED.

StageVerdict
Circuit definitionPASSED
SimulationPASSED
Result extractionPASSED
KiCad netlist generationPASSED
PCB creationPASSED
Footprint assignmentPASSED
PlacementPASSED
RoutingPASSED
DRCPASSED
Gerber exportPASSED
Drill exportPASSED
Schematic generationPARTIAL
SPICE netlist generationPARTIAL
ERCPARTIAL

See docs/smoke-test.md for per-stage evidence (exact JSON/CSV values).

Reproducing the tests

sh
# Model library validation (38/38 checks)
/usr/bin/python3 /Users/roberto/EDA/scripts/validate_models.py

# Individual SPICE testbenches
/opt/homebrew/bin/ngspice -b /Users/roberto/EDA/testbenches/01_op.cir
/opt/homebrew/bin/ngspice -b /Users/roberto/EDA/testbenches/04_tran.cir
# ... etc. for 02..08

# Full smoke-test pipeline (schematic -> sim -> PCB -> routing -> DRC -> gerbers)
zsh /Users/roberto/EDA/smoke/run_pipeline.sh

# Vendor freeze re-enforcement (idempotent)
/Users/roberto/EDA/scripts/freeze_vendor.sh

Further reading

  • docs/architecture.md — architecture decision detail (selected stack, rejected alternatives, source-of-truth contract).
  • docs/limitations.md — full limitations list with detail.
  • docs/smoke-test.md — per-stage smoke-test evidence.
  • AGENTS.md — subagent roster and delegation/operating rules.
  • models/README.md, models/PROVENANCE_CONVENTION.md, vendor/README.md — model library and provenance conventions (owned by the scaffolding agent, read here for reference).

Parts

2
QtyValueFootprintReferences
1100nFC_0805_2012MetricC1
110kR_0805_2012MetricR1

More from Bu3nd14/EDA

6
  • 2 layers392.6 × 198.3 mmAudio routed, the printed circuit board in 3D

    Audio routed

    Bu3nd14/EDA

    Scripted analog EDA + PCB automation environment (KiCad 10 + ngspice + SKiDL) for macOS Apple Silicon

    657 parts
  • 2 layers399 × 162.8 mmAudio routed, the printed circuit board in 3D

    Audio routed

    Bu3nd14/EDA

    Scripted analog EDA + PCB automation environment (KiCad 10 + ngspice + SKiDL) for macOS Apple Silicon

    462 parts
  • 2 layers218.6 × 100 mmPsu routed, the printed circuit board in 3D

    Psu routed

    Bu3nd14/EDA

    Scripted analog EDA + PCB automation environment (KiCad 10 + ngspice + SKiDL) for macOS Apple Silicon

    122 parts
  • 2 layers70 × 40 mmRc circuit, the printed circuit board in 3D

    Rc circuit

    Bu3nd14/EDA

    Scripted analog EDA + PCB automation environment (KiCad 10 + ngspice + SKiDL) for macOS Apple Silicon

    3 parts
  • 2 layers60 × 50 mmTest board ses imported, the printed circuit board in 3D

    Test board ses imported

    Bu3nd14/EDA

    Scripted analog EDA + PCB automation environment (KiCad 10 + ngspice + SKiDL) for macOS Apple Silicon

    2 parts
  • 2 layers60 × 50 mmTest board unrouted, the printed circuit board in 3D

    Test board unrouted

    Bu3nd14/EDA

    Scripted analog EDA + PCB automation environment (KiCad 10 + ngspice + SKiDL) for macOS Apple Silicon

    2 parts

Similar boards

  • 2 layers37 × 19 mmPassive rpi hub75-adapter, the printed circuit board in 3D

    Passive rpi hub75-adapter

    hzeller/rpi-rgb-led-matrix

    Controlling up to three chains of 64x64, 32x32, 16x32 or similar RGB LED displays using Raspberry Pi GPIO

    2 parts4.4kGPL-2.0
  • 2 layersDiode template, the printed circuit board in 3D

    Diode template

    adamws/kicad-kbplacer

    KiCad plugin for automatic keyboard's key placement and routing

    2 parts547GPL-3.0
  • 2 layers20.3 × 15.2 mmL0 button, the printed circuit board in 3D

    L0 button

    Luos-io/luos_engine

    Open-source and real-time orchestrator for cyber-physical-systems, to easily design, test and deploy embedded applications and digital twins.

    2 parts546MIT
  • 2 layers35.1 × 46.8 mmSDEX2M2 Breakout Board, the printed circuit board in 3D

    SDEX2M2 Breakout Board

    NVNTLabs/switch2-SDEX2M2

    Micro SD Express to M.2 NVME Adapter for Nintendo Switch 2

    2 parts542GPL-3.0
  • 2 layers59.3 × 36.6 mmExpansionBoardTemplate, the printed circuit board in 3D

    ExpansionBoardTemplate

    BlueSCSI/BlueSCSI-v2

    BlueSCSI v2/Ultra - an open source, open hardware, SCSI emulator using the Pi Pico PR2040 and Pico 2 RP2350

    2 parts459GPL-3.0
  • 2 layersAlpha.9mm.wire, the printed circuit board in 3D

    Alpha.9mm.wire

    ohmtech-rdi/eurorack-blocks

    Software to Hardware Prototyping for Eurorack using C++, Max/Gen~ or Faust

    2 parts410
  • 2 layers26.7 × 64 mmGpu power, the printed circuit board in 3D

    Gpu power

    dennisss/dacha

    Monorepo for awesome tools/projects/libraries

    2 parts397Apache-2.0

Questions

How big is the Test board PCB?

It measures 60 × 50 mm and has 2 copper layers, 1.6 mm thick.

What parts does the Test board use?

2 parts. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.

Where can I download the Test board KiCad files?

From the Bu3nd14/EDA repository on GitHub, at the commit this page was made from: the board is pcb/test_board.kicad_pcb and its schematic smoke/rc_circuit.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the Test board design in my own project?

Its repository states no licence, so its author keeps all rights: ask Bu3nd14 before reusing the design.