You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 07f7c0f
Browse filesBrowse the repository at this point in the historyBrowse files
LTspice mode covers fixture-backed generated-netlist syntax such as `.backanno` and selected output/viewer options as warning no-ops, one-argument `.TRAN`, scalar expression aliases, finite-cycle `PULSE(... Ncycles)`, `EXP(...)`, independent-source `tbl=(...)`, R/C model `tc=a[,b]`, and switch threshold aliases. Behavior-changing constructs that are not represented by SpiceSharp are reported with targeted diagnostics instead of being silently ignored.
126
+
LTspice mode covers syntax such as:
127
+
128
+
-`.backanno` and selected output/viewer options as warning no-ops
129
+
- one-argument `.TRAN` with a derived step policy
130
+
- scalar expression aliases and `table(...)` / `tbl(...)`
131
+
- source waveforms including `EXP(...)`, finite-cycle `PULSE(... Ncycles)`, finite-cycle `SINE(... Ncycles)`, and local two-column `PWL file=<path>` data
132
+
- independent-source topology options: `Rser`, `Cpar`, `load`, and `R=<value>`
133
+
- model parameter aliases: resistor and capacitor models accept `tc=<tc1>[,<tc2>]`; voltage switches accept `von` / `voff`; current switches accept `ion` / `ioff`
134
+
- resistor instance parasitics `Rser`, `Rpar`, and `Cpar`
135
+
- capacitor instance parasitics `Rser`, `Lser`, `Rpar`, and `Cpar`
136
+
137
+
Topology-changing LTspice options that can be represented safely are synthesized as helper components in the parser. Behavior-changing constructs that are not represented by SpiceSharp are reported with targeted diagnostics instead of being silently ignored.
127
138
128
139
See the [LTspice compatibility matrix](roadmap/ltspice-compatibility-matrix.md) and [LTspice netlist compatibility plan](roadmap/ltspice-netlist-compatibility-plan.md) for the current support classes, known gaps, and evidence policy. LTspice schematic and symbol import (`.asc` / `.asy`) is out of scope.
Copy file name to clipboardExpand all lines: roadmap/ltspice-compatibility-matrix.md
+4-2Lines changed: 4 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
---
2
2
title: LTspice Compatibility Matrix
3
-
status: P3 Baseline + .FOUR Support Refresh + Custom Passives + Ideal Diodes + Golden Evidence + Include/Lib Path Evidence + Waveform Docs Refresh + PWL Text Variants + Finite SINE + Source Parasitics
3
+
status: P3 Baseline + .FOUR Support Refresh + Custom Passives + Ideal Diodes + Golden Evidence + Include/Lib Path Evidence + Waveform Docs Refresh + PWL Text Variants + Finite SINE + Source/R-C Parasitics
4
4
scope: SpiceSharpParser + SpiceSharp
5
5
last_reviewed: 2026-07-06
6
6
---
@@ -63,7 +63,9 @@ Compatibility classes:
63
63
| Source `Rser`, `Cpar`, `load`, `R=<value>`| Accepted | Synthesizes helper R/C entities in LTspice mode | OP supported for resistance helpers; Cpar read fixture | Analytic/parser fixture | Malformed value forms produce targeted LTspice source-option diagnostics | Current parser/runtime | Parser-only topology synthesis: `Rser` adds a series resistor, `Cpar` adds a shunt capacitor, `load` adds a shunt resistor, and `R=<value>` maps to series resistance on voltage sources and load resistance on current sources. Core source models are unchanged. |
64
64
| R/C model `tc=a[,b]`| Accepted | Lowered to `tc1` / `tc2`| Existing R/C model behavior | Read fixture | None expected in LTspice mode | Current parser/runtime | Parser shim only; coefficients beyond two are rejected. |
65
65
| LTspice metadata/rating parameters `mfg`, `manufacturer`, `pn`, `part`, `desc`, `description`, `V`, `Irms`, `Ipk`| Accepted | Warning no-op in LTspice mode | No runtime effect | Diagnostic fixture | Default: existing parameter error. LTspice: warning names parameter. | Current parser/runtime | BOM/layout metadata is not used by SpiceSharpParser. |
66
-
| R/C/L instance parasitics `Rser`, `Rpar`, `Cpar`, `Lser`, `RLshunt`| Accepted | Rejected in LTspice mode | Not runnable | None | Targeted LTspice instance-parameter error names parameter | Current parser/runtime | Topology-changing passive parasitics are not synthesized. |
66
+
| Resistor instance parasitics `Rser`, `Rpar`, `Cpar`| Accepted in LTspice mode | Synthesizes helper R/C entities | OP/TRAN supported | Analytic fixture | None expected for supported forms | Current parser/runtime | Parser-only topology synthesis: `Rser` adds a series resistor through an internal node; `Rpar` and `Cpar` add shunts across the resistor terminals. Core resistor model is unchanged. |
67
+
| Capacitor instance parasitics `Rser`, `Lser`, `Rpar`, `Cpar`| Accepted in LTspice mode | Synthesizes helper R/L/C entities | OP/TRAN supported for R helpers and `Cpar`; `Lser` read fixture | Analytic/parser fixture | None expected for supported forms | Current parser/runtime | Parser-only topology synthesis: `Rser` and `Lser` add a series chain through internal nodes; `Rpar` and `Cpar` add shunts across the capacitor terminals. Core capacitor model is unchanged. |
68
+
| Remaining inductor instance parasitics `Rser`, `Rpar`, `Cpar`, `Lser`, `RLshunt`| Accepted | Rejected in LTspice mode | Not runnable | None | Targeted LTspice instance-parameter error names parameter | Current parser/runtime | Topology-changing inductor parasitics are not synthesized yet; resistor/capacitor forms are tracked separately above. |
67
69
| Capacitor `Q=<expr>` and inductor `Flux=<expr>`| Accepted | Core LTspice mode: targeted diagnostic. With `UseCustomComponents()`: produces `NonlinearCapacitor` / `NonlinearInductor`. | Custom components: TRAN and AC supported with operating-point incremental capacitance/inductance. | Focused parser/TRAN/AC fixtures plus optional LTspice-backed AC/TRAN golden comparisons | Core LTspice mode still emits targeted charge/flux diagnostic when custom mappings are not enabled |`SpiceSharpParser.CustomComponents`|`Q` uses `x` as terminal voltage and supports `IC`, `M`, and `N`; `Flux` uses `x` as branch current. Optional goldens compare AC small-signal voltage and transient waveform samples against LTspice when `LTSPICE_EXE` is configured. |
68
70
| LTspice ideal diode parameters `Ron`, `Roff`, `Vfwd`, `Vrev`, `Rrev`, `Ilimit`, `RevIlimit`, `Epsilon`, `RevEpsilon`| Accepted | Core LTspice mode: targeted diagnostic. With `UseCustomComponents()`: produces `IdealDiodeModel` / `IdealDiode`. | Custom component: OP/DC/AC/TRAN supported as a memoryless nonlinear conductance. | Focused parser/integration/unit fixtures plus optional LTspice-backed DC sweep, AC, and rectifier-transient golden comparisons | Core LTspice mode still emits targeted ideal-diode diagnostics when custom mappings are not enabled |`SpiceSharpParser.CustomComponents`| These select LTspice's idealized diode behavior, not Berkeley diode parameters. The custom component supports model parameters, instance overrides, `M`/`N` scaling, `OFF`, and L/W model-bin selection; it does not model junction charge, capacitance, semiconductor noise, or temperature physics. |
69
71
| Switch aliases `von`/`voff` and `ion`/`ioff`| Accepted | Lowered to `vt`/`vh` and `it`/`ih`| Existing switch model behavior | Read fixture | Missing pair or mixed native/alias forms are targeted errors | Current parser/runtime | Midpoint and half-span lowering only; no LTspice numeric parity claim. |
Copy file name to clipboardExpand all lines: roadmap/ltspice-netlist-compatibility-plan.md
+5-3Lines changed: 5 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -42,7 +42,7 @@ This roadmap is intentionally parser-first and evidence-first:
42
42
- MOS model generation currently covers legacy levels 1, 2, and 3. LTspice `VDMOS` and advanced monolithic levels such as BSIM/EKV/HiSIM variants are runtime or intentional-unsupported candidates.
43
43
- Distributed-line support currently starts from lossless `T`. LTspice lossy `O` / `LTRA` and uniform RC-line `URC` models need engine triage before runnable support is claimed.
44
44
- P3 LTspice mode maps R/C model `tc=a[,b]`, switch `von`/`voff`, and current-switch `ion`/`ioff` aliases where they lower to existing parameters.
45
-
- P3 LTspice mode warns on recognized metadata/rating parametersand emits targeted errors for topology-changing passive parasitics, ideal-diode parameters when custom mappings are not enabled, switch current-limiting/series options, `VDMOS`, high MOS levels, three-terminal power-MOS syntax, and `O` / `LTRA` / `U` / `URC` line families. The optional custom component package adds runnable `IdealDiode` support for LTspice-style diode parameters plus `NonlinearCapacitor` / `NonlinearInductor` support for LTspice-style capacitor `Q=` and inductor `Flux=` forms when `UseCustomComponents()` is enabled, with optional LTspice-backed DC/AC/transient golden comparisons when `LTSPICE_EXE` is configured.
45
+
- P3 LTspice mode warns on recognized metadata/rating parameters, synthesizes resistor `Rser` / `Rpar` / `Cpar`and capacitor `Rser` / `Lser` / `Rpar` / `Cpar` helper topology, and emits targeted errors for remaining topology-changing passive parasitics, ideal-diode parameters when custom mappings are not enabled, switch current-limiting/series options, `VDMOS`, high MOS levels, three-terminal power-MOS syntax, and `O` / `LTRA` / `U` / `URC` line families. The optional custom component package adds runnable `IdealDiode` support for LTspice-style diode parameters plus `NonlinearCapacitor` / `NonlinearInductor` support for LTspice-style capacitor `Q=` and inductor `Flux=` forms when `UseCustomComponents()` is enabled, with optional LTspice-backed DC/AC/transient golden comparisons when `LTSPICE_EXE` is configured.
46
46
47
47
## Scope And Policy
48
48
@@ -239,12 +239,14 @@ Implemented P3 behavior:
239
239
- Mapped R/C model `tc=a[,b]` aliases to `tc1` / `tc2`.
240
240
- Mapped switch `von` / `voff` and current-switch `ion` / `ioff` aliases to midpoint/hysteresis parameters.
241
241
- Warned on recognized LTspice metadata and rating parameters only in LTspice mode.
242
-
- Added targeted diagnostics for topology-changing passive parasitics, LTspice ideal-diode parameters when custom mappings are not enabled, switch `Lser` / `Vser` / `Ilimit`, high MOS levels, `VDMOS`, three-terminal power-MOS syntax, and `O` / `LTRA` / `U` / `URC` line families. LTspice ideal-diode parameters, capacitor `Q=`, and inductor `Flux=` remain targeted diagnostics in core LTspice mode but are runnable through `SpiceSharpParser.CustomComponents` as `IdealDiode`, `NonlinearCapacitor`, and `NonlinearInductor`, with optional LTspice-backed DC/AC/transient golden evidence.
242
+
- Added LTspice-mode parser synthesis for resistor instance parasitics: `Rser` adds a series resistor through an internal node, while `Rpar` and `Cpar` add shunts across the resistor terminals.
243
+
- Added LTspice-mode parser synthesis for capacitor instance parasitics: `Rser` and `Lser` add a series helper chain through internal nodes, while `Rpar` and `Cpar` add shunts across the capacitor terminals.
244
+
- Added targeted diagnostics for remaining topology-changing passive parasitics, LTspice ideal-diode parameters when custom mappings are not enabled, switch `Lser` / `Vser` / `Ilimit`, high MOS levels, `VDMOS`, three-terminal power-MOS syntax, and `O` / `LTRA` / `U` / `URC` line families. LTspice ideal-diode parameters, capacitor `Q=`, and inductor `Flux=` remain targeted diagnostics in core LTspice mode but are runnable through `SpiceSharpParser.CustomComponents` as `IdealDiode`, `NonlinearCapacitor`, and `NonlinearInductor`, with optional LTspice-backed DC/AC/transient golden evidence.
243
245
244
246
Remaining follow-up:
245
247
246
248
- Broaden model-family alias tables only when direct SpiceSharp equivalents are confirmed by fixtures.
247
-
- Add engine work before claiming runnable support for `VDMOS`, advanced MOS families, lossy transmission lines, uniform RC lines, or synthesized passive parasitics.
249
+
- Add engine or parser-synthesis work before claiming runnable support for `VDMOS`, advanced MOS families, lossy transmission lines, uniform RC lines, or remaining inductor passive parasitics.
0 commit comments