Skip to content
Testing
Skill

/emc

EMC pre-compliance risk analysis for KiCad PCB designs — 18 check categories, 44 rule IDs covering ground planes, decoupling, I/O filtering, switching harmonics, clock routing, differential pair skew, board edge radiation, PDN impedance, return paths, crosstalk, ESD protection,

From plugin
kicad-happy
91911 skills
Install
$ npx -y skills add aklofas/kicad-happy --skill emc --agent claude-code

How it fires

How this skill gets triggered: by you, by Claude, or both.

  • Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
  • You can call itInvoke it directly when you want it.
  • Slash command/emc

Context preview

The summary Claude sees to decide when to auto-load this skill.

EMC pre-compliance risk analysis for KiCad PCB designs — 18 check categories, 44 rule IDs covering ground planes, decoupling, I/O filtering, switching harmonics, clock routing, differential pair skew, board edge radiation, PDN impedance, return paths, crosstalk, ESD protection,

SKILL.md

emc.SKILL.md
name: emc
description: >-
  EMC pre-compliance risk analysis for KiCad PCB designs — 18 check categories,
  44 rule IDs covering ground planes, decoupling, I/O filtering, switching
  harmonics, clock routing, differential pair skew, board edge radiation, PDN
  impedance, return paths, crosstalk, ESD protection, shielding, and magnetic
  leakage from switching inductors. Produces
  severity-ranked risk report with pre-compliance test plan. Supports FCC
  Part 15, CISPR 32, CISPR 25 (automotive), MIL-STD-461G. SPICE-enhanced when
  available. Use when the user asks about EMC, EMI, radiated/conducted
  emissions, FCC compliance, CE marking, CISPR, ground plane issues, decoupling
  strategy, clock routing EMC, switching noise, differential pair skew, or
  whether their board will pass EMC testing. Also for "will this pass FCC?",
  "check my EMC", "is my ground plane okay?", "check my decoupling", or
  "generate an EMC test plan".

EMC Pre-Compliance Skill

Automated EMC risk analysis for KiCad PCB designs. Identifies the most common causes of EMC test failures using geometric rule checks, analytical emission formulas, and optional SPICE simulation.

**This is a risk analyzer, not a compliance predictor.** It catches ~70% of common EMC design mistakes before fabrication. It cannot guarantee FCC/CISPR compliance — only a calibrated measurement in an accredited lab can do that. But it can reduce the first-spin failure rate from ~50% toward ~20-30%, potentially saving $5K-$50K per avoided board respin.

Related Skills

| Skill | Purpose | |-------|---------| | `kicad` | Schematic/PCB analysis — produces the analyzer JSON this skill consumes | | `kicad` (thermal) | Thermal hotspot analysis — MLCC derating and ferrite/inductor overheating findings can amplify EMC decoupling and filter issues (an over-stressed MLCC degrades; a hot ferrite drifts impedance). Worth cross-checking when EMC flags DC-001/DC-002 or EF-001/EF-002. | | `spice` | SPICE simulation — provides simulator backend for SPICE-enhanced PDN/filter checks |

**Handoff guidance:** Run the `kicad` skill's `analyze_schematic.py` and `analyze_pcb.py` first — this skill consumes their JSON output. Use `--full` on the PCB analyzer for best results (enables per-track coordinates for ground plane crossing, edge proximity, and return path checks). During a design review, run EMC analysis after the schematic/PCB analyzers, SPICE simulation, and thermal analysis, then incorporate EMC findings into the report.

Requirements

  • **Python 3.10+** — stdlib only, no pip dependencies
  • **Schematic analyzer JSON** — from `analyze_schematic.py --output`
  • **PCB analyzer JSON** — from `analyze_pcb.py --full --output` (recommended with `--full`)
  • **SPICE simulator** *(optional)* — ngspice, LTspice, or Xyce for SPICE-enhanced PDN/filter checks. Auto-detected. Without one, analytical models run unchanged.

Workflow

Step 1: Run the analyzers

python3 <kicad-skill-path>/scripts/analyze_schematic.py design.kicad_sch --analysis-dir analysis/
python3 <kicad-skill-path>/scripts/analyze_pcb.py design.kicad_pcb --full --analysis-dir analysis/

Step 2: Run EMC analysis

Pass `--analysis-dir analysis/` — the script auto-resolves `schematic.json` and `pcb.json` from the manifest's current run, and writes `emc.json` into the same folder so the manifest tracks it.

# Recommended: auto-resolve inputs from the current run
python3 <skill-path>/scripts/analyze_emc.py --analysis-dir analysis/

# Equivalent — explicit paths still accepted (and required if you want to
# point at a non-current run or override one input)
python3 <skill-path>/scripts/analyze_emc.py \
    --schematic analysis/<run_id>/schematic.json \
    --pcb analysis/<run_id>/pcb.json \
    --analysis-dir analysis/

# One-off JSON (bypasses the cache)
python3 <skill-path>/scripts/analyze_emc.py --schematic schematic.json --pcb pcb.json --output emc.json

# SPICE-enhanced (improved PDN and filter accuracy)
python3 <skill-path>/scripts/analyze_emc.py --analysis-dir analysis/ --spice-enhanced

# Select target standard
python3 <skill-path>/scripts/analyze_emc.py --analysis-dir analysis/ --standard cispr-class-b

# Select target market (sets all applicable standards)
python3 <skill-path>/scripts/analyze_emc.py --analysis-dir analysis/ --market eu

# Filter by severity
python3 <skill-path>/scripts/analyze_emc.py --analysis-dir analysis/ --severity high

# Human-readable text output
python3 <skill-path>/scripts/analyze_emc.py --analysis-dir analysis/ --text

Step 3: Interpret results

Read the JSON report and incorporate findings into the design review. Each finding has a severity, rule ID, description, and actionable recommendation. See "Interpreting Results" below.

What Gets Checked

44 rule IDs across 18 categories. Each rule has a specific threshold, rationale, and source citation — see `references/pcb-emc-rules.md` for full details.

| Category | Rules | What it detects | |----------|-------|-----------------| | **Ground plane** | GP-001 to GP-005 | Signal crossing voids, zone fragmentation, missing ground planes, low fill ratio, multiple ground domains | | **Decoupling** | DC-001 to DC-003 | Cap too far from IC, IC with no decoupling cap, cap too far from via | | **I/O filtering** | IO-001, IO-002 | Connector without filtering, insufficient ground pins | | **Switching EMC** | SW-001 to SW-003 | Harmonic overlap, switching node copper area, input cap loop area | | **Clock routing** | CK-001 to CK-003 | Clock on outer layer, long trace, clock near connector | | **Via stitching** | VS-001 | Ground via spacing exceeds λ/20 at highest frequency | | **Stackup** | SU-001 to SU-003 | Adjacent signal layers, signal far from reference plane, thin interplane capacitance | | **Diff pair** | DP-001 to DP-004 | Intra-pair skew vs protocol limits, CM radiation, reference plane change, outer layer routing | | **Board edge** | BE-001 to BE-003 | Signal near edge, incomp

Read more
Ships withkicad-happy

AI-powered design review for KiCad. Analyzes schematics, PCB layouts, and Gerbers. Catches real bugs before you order boards.

Get the whole plugin
Stats
920
Stars
70
Forks
Active
Maintenance
Python
Language
MIT
License
8d ago
Last commit
5mo ago
Created

Repo: aklofas/kicad-happy

Other skills on kicad-happy.