Diode model parameter m is not the area parameter, and thus should not be copied to the diode instance line
Description
When attaching a model parameter set to a diode symbol, which contains a parameter entry like m=0.55, this is now copied to the instance line of the diode (D line). This is wrong, as the diode model parameter m is a 'Grading coefficient' for calculating the junction capacitance, not the area multiplicator. This bug happens in 7.99 and 7.01.
The area multiplicator has to be added to the instance line by the user during designing the circuit (not very useful if you simulate discrete devices, but sometimes applied during IC design).
Steps to reproduce
- Load the attached project
- Start the simulator window
- Watch the resulting ngspice netlist, which now contains a line 'D1 Net-D1-A out D1N4148 m=0.55' with the wrongly attached m=0.55.
KiCad Version
Application: KiCad Schematic Editor x64 on x64
Version: 7.99.0-558-gedf6828cf1, release build
Libraries:
wxWidgets 3.2.2
FreeType 2.12.1
HarfBuzz 6.0.0
FontConfig 2.14.1
libcurl/7.88.1-DEV Schannel zlib/1.2.13
Platform: Windows 10 (build 19044), 64-bit edition, 64 bit, Little endian, wxMSW
Build Info:
Date: Mar 21 2023 06:21:01
wxWidgets: 3.2.2 (wchar_t,wx containers)
Boost: 1.81.0
OCC: 7.6.3
Curl: 7.88.1-DEV
ngspice: 39
Compiler: Visual C++ 1934 without C++ ABI
Build settings:
KICAD_SPICE=ON
Edited by holvo