metronome/hardware/eda/Containerfile
Me Here 3f7f4b94d9 PM_K-1 hardware: Stage 1 input receiver as SKiDL (code-defined schematic)
Capture method = SKiDL per decision. circuits/stage1_input.py defines the
balanced line receiver + per-leg protection (DC-block film cap, series R, bias R,
clamp diodes to the rails) and emits a KiCad netlist. ERC: 0 errors (2 expected
warnings -- AIN_HOT/COLD reach only one pin until the interconnect block exists).

Container: env vars point SKiDL/KiCad at the symbol/footprint libs.

VERIFY-before-layout flagged in-file: exact THAT124x gain suffix, its SO-8 pin
numbers, clamp-diode orientation.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-05-30 19:43:07 -05:00

36 lines
1.4 KiB
Docker

# Reproducible EDA toolchain for the PM_K-1 core board.
#
# Why this exists: the system KiCad is 7.0 (no CLI ERC). This pins a known,
# rebuildable environment so the design can be checked/simulated identically
# years from now — fitting for a device meant to outlive its tools.
#
# KiCad 9 -> schematic capture, CLI ERC/DRC, netlist/PDF/Gerber export
# ngspice -> SPICE simulation of the analog audio circuits
# python3 -> scripting / BOM / skidl-style helpers
#
# Build/run via ../eda/run.sh (or: podman build -t pmk1-eda:9.0 .)
FROM docker.io/library/ubuntu:24.04
ENV DEBIAN_FRONTEND=noninteractive
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
RUN apt-get update && apt-get install -y --no-install-recommends \
software-properties-common ca-certificates gnupg && \
add-apt-repository -y ppa:kicad/kicad-9.0-releases && \
apt-get update && apt-get install -y --no-install-recommends \
kicad \
kicad-symbols \
kicad-footprints \
ngspice \
python3 python3-pip python3-venv \
git make && \
apt-get clean && rm -rf /var/lib/apt/lists/* && \
pip3 install --no-cache-dir --break-system-packages skidl
# Point SKiDL / KiCad CLI at the installed libraries (reproducible, not ad-hoc).
ENV KICAD9_SYMBOL_DIR=/usr/share/kicad/symbols \
KICAD9_FOOTPRINT_DIR=/usr/share/kicad/footprints \
KICAD_SYMBOL_DIR=/usr/share/kicad/symbols
WORKDIR /work
CMD ["bash"]