hashgraph-online/awesome-codex-plugins / plugins/aklofas/kicad-happy/skills/kicad
kicad
VerifiedAnalyze KiCad projects and PDF schematics: schematics, PCB layouts, Gerbers, footprints, symbols, netlists, and design rules. Reviews designs for bugs, traces nets, cross-references schematic to PCB, extracts BOM data, checks DRC/ERC, DFM, power trees, and regulator circuits. Every finding carries a confidence label and evidence source with trust_summary rollup. Analyzes PDF schematics from dev boards, reference designs, eval kits, and datasheets. Supports KiCad 5–10. Use whenever the user mentions .kicad_sch, .kicad_pcb, .kicad_pro, PCB design review, schematic analysis, PDF schematics, reference designs, Gerber files, DRC/ERC, netlist issues, BOM extraction, signal tracing, power budget, DFM, or wants to understand, debug, compare, or review any hardware design. Also for "check my board", "review before fab", "what's wrong with my schematic", "is this ready to order", "check my power supply", "verify this circuit", OSHWA certification readiness, or any electronics/PCB design question.
scripts/kicad_core/pairing.py
View on GitHub"""Schematic part <-> PCB footprint pairing (kicad_core), as KiCad's Update PCB pairs them."""
from __future__ import annotations
def _part_ref(ref) -> bool:
return isinstance(ref, str) and bool(ref) and not ref.startswith('#')
def pair_by_path(schematic: dict, pcb: dict) -> tuple[list[tuple[str, dict]], set, set]:
"""Pair PCB footprints with schematic references as KiCad's Update PCB does: a
footprint whose (path) is a unit's instance path belongs to that symbol whatever its
reference; a footprint with no such path pairs by reference (KiCad's relink mode).
Returns (pairs sorted by schematic then PCB reference, schematic references with no
footprint, references of footprints with no symbol)."""
by_path: dict[str, str] = {}
sch_refs = set()
for c in schematic.get('components', []):
ref = c.get('reference', '')
if not _part_ref(ref):
continue
sch_refs.add(ref)
path = c.get('instance_path')
if isinstance(path, str) and path:
by_path.setdefault(path.lower(), ref)
pairs: list[tuple[str, dict]] = []
unmatched: list[dict] = []
for fp in pcb.get('footprints', []):
if not _part_ref(fp.get('reference', '')):
continue
path = fp.get('sch_path')
hit = by_path.get(path.lower()) if isinstance(path, str) and path else None
if hit:
pairs.append((hit, fp))
else:
unmatched.append(fp)
path_paired = {ref for ref, _ in pairs}
pcb_only = set()
for fp in unmatched:
ref = fp['reference']
if ref in sch_refs and ref not in path_paired:
pairs.append((ref, fp))
else:
pcb_only.add(ref)
pairs.sort(key=lambda p: (p[0], p[1].get('reference', ''), str(p[1].get('sch_path') or '')))
return pairs, sch_refs - {ref for ref, _ in pairs}, pcb_only
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| finishing-a-development-branchobra/superpowersUse when implementation is complete, all tests pass, and you need to decide how to integrate the work | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| systematic-debuggingobra/superpowersUse when encountering any bug, test failure, or unexpected behavior, before proposing fixes | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| test-driven-developmentobra/superpowersUse when implementing any feature or bugfix, before writing implementation code | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| skill-creatoranthropics/skillsCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy. | Stars: 197k | Updated | Claude CodeCodex | Verified | Install |