Skip to main content
ReviewEMC/EMI pre-simulationFreeNewv1.0.0

EMC 辐射预合规计算

FCC/CISPR 辐射限值余量、环路/线缆辐射反解最大环面积与共模电流、梯形波开关谐波谱、板腔谐振模式、差分偏斜转共模,以及实测谱对限值曲线筛查;离线契约报告 + CSV。

Installs: 0Rating: –Updated:
Claude CodeCursorCodexGemini CLI+3

Badges only claim the demo-run passed on that host; cross-host installation is handled by the adapter layer.

Preview gallery

You say
Run this EMC input: margin-check a 100 MHz switching loop and USB cable radiation, list 500 kHz switching harmonics, cavity modes and PCIe skew, and screen the pre-scan against a CISPR-style profile.

Content matches the files inside the package; extracted by the publish pipeline.

LCEDA EMC pre-compliance bundle

Offline Node rewrite of the pure-math cores of the MIT-licensed kicad-happy agent skills (see references/PROVENANCE.md): the EMC formula collection (Ott / Paul / Bogatin references) and the harmonic-limit screening tool. Editor-bound steps (harvesting loop geometry, CM current measurement) are procedures in references/procedures.md; a power-layout review checklist derived from AI-PCB-layout (CC-BY-4.0) ships as references/power-layout-review.md.

What the script computes

scripts/demo.mjs (Node >= 20, no dependencies):

  • Radiated limits: FCC Part 15 Class A/B and CISPR Class A/B tables; at a band edge the tighter limit applies.
  • Differential-mode loop radiation E = K f² A I / r (K = 2.632e-14 with ground plane, 1.316e-14 free space), in dBµV/m, plus the max loop area that keeps a 6 dB (configurable) margin.
  • Common-mode cable radiation E = 1.257e-6 f L I_CM / r and the max CM current in µA for the same margin.
  • Trapezoidal switching spectrum A_n = |2 V D sinc(nπD) sinc(nπt_r/T)|, envelope corners 1/(πτ) and 1/(πt_r), knee 0.5/t_r, 3 dB BW 0.35/t_r, λ/20 via-stitching spacing in FR-4.
  • Parallel-plate board cavity modes f_mn = (c/2√εr)√((m/L)²+(n/W)²).
  • Diff-pair length-mismatch skew (ps/mm from √((εr+1)/2)/c) against protocol limits (USB/PCIe/HDMI/LVDS/Ethernet/CAN/…), and the skew- induced common-mode voltage V_CM = V_diff Δt / (2 t_r).
  • Harmonic screening: measured spectrum lines vs a user-supplied limit profile (flat or log-frequency-sloped limits, peak/quasi-peak/average columns), worst-margin point per band, above/near/below status. Screening only — never a compliance determination.

Run

node scripts/demo.mjs --out-dir <dir> [--input <emc.json>]

Default input: scripts/fixtures/input.json. stdout is an edaskills.report.v1 report; <dir> receives emissions.csv, harmonics.csv, cavity.csv.

Input shape: { "standard", "designMarginDb", "loops": [{ "id", "freqMHz", "areaCm2", "currentA", "groundPlane"? }], "cables": [{ "id", "freqMHz", "lengthM", "cmCurrentUa" }], "switching": { "fswHz", "vPeak", "duty", "riseNs" }, "board": { "lengthMm", "widthMm", "er" }, "diffPairs": [{ "net", "protocol", "lengthDiffMm" }], "spectrum"?, "profile"? }.

When to use

  • Before layout review: bound the switching-loop area and cable CM current that can pass a radiated-emissions pre-scan.
  • Explain which harmonics of a converter land in the 30–1000 MHz band.
  • Screen a bench pre-scan against a limit profile with design margin.

Not for: compliance sign-off (no detector emulation, no antenna factor or chamber correction), near-field probes, or conducted emissions.

What you get

  • Loop/cable radiation in dBuV/m with limit margins; max loop area / CM current bounds when over
  • Switching harmonic spectrum, envelope corners, knee frequency and lambda/20 stitching spacing
  • Board cavity modes, diff-pair skew-to-CM voltage, and measured-spectrum vs limit-profile screening

Good fit for

  • Pre-layout bounds on hot-loop area and cable CM current for a radiated pre-scan
  • Explaining which converter harmonics land in the 30-1000 MHz band
  • Screening bench pre-scan lines against a standard excerpt with design margin

Not for

  • Compliance sign-off (no detector emulation or chamber corrections; screening only)
  • Conducted emissions / harmonic-current limits (radiated tables only)
Before you start

You provide

  • Loops: freq MHz, area cm2, peak current A; cables: length m, CM current uA
  • Switching: fsw, peak voltage, duty, rise time ns; board size mm
  • Optional: diff-pair protocol + length mismatch mm, measured spectrum + limit profile JSON

Environment

  • node ≥ 20

Last tested

v1.0.0 · Claude Code, Cursor, Codex, Gemini CLI · Ran 2026/11/19

Dependencies

No dependencies
This skill works standalone.

Demo run

Failed verification1 errors · 4 warnings

node v24.19.0 · 2026/11/19

  • [error] DM_EXCEED (SW_LOOP): SW_LOOP loop radiation 44.9 dBuV/m exceeds fcc-class-b limit 43.5 by 1.4 dB; shrink loop to <= 0.085 cm^2
  • [info] DM_OK (CLK_LOOP): CLK_LOOP 24.9 dBuV/m, margin 18.6 dB
  • [warning] CM_MARGIN_LOW (USB_CABLE): USB_CABLE margin 1.5 dB below 6 dB design margin
  • [info] CM_OK (PWR_CABLE): PWR_CABLE 32.4 dBuV/m, margin 7.6 dB
  • [info] SW_SPECTRUM (switching): 2000 harmonics of 500 kHz; envelope corners 0.40/15.92 MHz; 1941 lines in 30-1000 MHz radiated band (amplitude is node voltage, not field strength)

FAQ

Ratings & reviews

Not rated0 ratings

5 star0
4 star0
3 star0
2 star0
1 star0

Sign in to rate this skill.

Sign in

Versions

  • v1.0.0Latest319.0 KB

    首发种子版本。

    License: MITSourceSHA-256: 6af313f4f343c657…

Related skills