Skip to content

feat: add analog stimulus and measurements - #2908

Draft
ShiboSoftwareDev wants to merge 5 commits into
mainfrom
feat/tps63802-rfc-simulations
Draft

feat: add analog stimulus and measurements#2908
ShiboSoftwareDev wants to merge 5 commits into
mainfrom
feat/tps63802-rfc-simulations

Conversation

@ShiboSoftwareDev

@ShiboSoftwareDev ShiboSoftwareDev commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add piecewise-linear voltage and current source waveforms
  • support multidimensional parameter sweeps and scalar transient measurements
  • keep measurement callbacks in TypeScript and emit conventional Circuit JSON results
  • deduplicate implicit measurement probes by electrical connectivity

Dependencies

This PR intentionally remains a draft until the schema packages are merged and released:

The current CI failures are caused by npm resolving circuit-json@0.0.455 and @tscircuit/props@0.0.602, which predate the RFC records and props. After those two releases, this PR only needs their versioned dev-dependency bumps; peer dependencies remain *.

Root cause of the probe fix

An explicit voltage probe and an implicit measurement probe could target the same SPICE vector. The later implicit metadata shadowed the explicit probe ID, so getVoltage(...) could not find the returned transient graph. Implicit probes now share connectivity keys and are omitted when an equivalent explicit probe exists.

Validation

  • bun test tests/features/spice-analysis/analog-transient-measurements.test.tsx
  • bun test tests/features/spice-analysis (new and assertion-based tests pass; three pre-existing ngspice SVG snapshots drift under the local engine)
  • bunx tsc --noEmit
  • Biome checks for all changed TypeScript files
  • npm pack --dry-run: the release tarball contains AnalogMeasurement, waveform handling, and measurement-result emission
  • git diff --check

@vercel

vercel Bot commented Jul 28, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
tscircuit-core-benchmarks Error Error Jul 31, 2026 10:25am

Request Review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant