Maciej Suminski
d7e1152aa3
Correct way of freeing memory in NGSPICE class
...
Strings created with strdup() should be deleted using free(), not
delete.
2017-03-01 13:56:24 +01:00
Maciej Suminski
af3d5befa7
Solve codemodel libraries loading problem in ngspice
...
Fixes: lp:1630675
* https://bugs.launchpad.net/kicad/+bug/1630675
2016-10-17 10:11:27 +02:00
Maciej Suminski
2a6b8f153b
NGSPICE as a singleton
...
One cannot call ngSpice_Init() twice without unloading the dll. When calling
ngSpice_Init, we pass a pointer to a NGSPICE instance and thus it cannot be changed.
When any of the callback function is called with a stale pointer everything crashes.
2016-08-19 15:51:19 +02:00
Maciej Suminski
cac571c056
Initialize ngspice only once
2016-08-18 18:10:00 +02:00
Maciej Suminski
43d93682a2
Fix locale in NGSPICE methods using LOCALE_IO instead of setlocale.
...
More information: https://lists.launchpad.net/kicad-developers/msg25763.html
2016-08-15 15:52:07 +02:00
Maciej Suminski
75f8b20493
libngspice is linked at compile time
2016-08-15 13:52:13 +02:00
Maciej Suminski
18e99fa30f
Fixed a crash with certain shared library versions
2016-08-11 14:42:21 +02:00
Maciej Suminski
0667b7ba63
Fixed ngspice freeze when there is an error in the simulated netlist Does not work with current ngspice head, it has to be compiled from the official master branch.
2016-08-11 14:42:18 +02:00
Maciej Suminski
eeeb3e0a9a
Simulator code formatting and clean up
2016-08-11 14:42:17 +02:00
Maciej Suminski
957c6ec417
Removed hard limit for ngspice netlist
2016-08-11 14:42:17 +02:00
Maciej Suminski
0a6390701d
NGSPICE uses a more convenient function to generate DLL name
2016-08-11 14:42:16 +02:00
Johannes Maibaum
c78462c4f5
sim: Modifications to compile the simulator on OSX.
2016-08-11 14:42:15 +02:00
Tomasz Wlostowski
36297f84c3
sim: further locale hacks, fixed plot/welcome message sizing
2016-08-11 14:42:02 +02:00
Tomasz Wlostowski
bba57097b7
sim: use C locale for SPICE simulation. Added error callback
2016-08-11 14:42:01 +02:00
Tomasz Wlostowski
ec1b8be528
sim: fixed build errors & locale issues
2016-08-11 14:41:58 +02:00
Maciej Suminski
caef84d622
SPICE_SIMULATOR::GetXAxis()
2016-08-11 14:41:51 +02:00
Maciej Suminski
d869771f04
Display an error message if ngspice DLL is missing
2016-08-11 14:41:48 +02:00
Maciej Suminski
f62a6425a3
Changed the simulator code license to GPLv3+
2016-08-11 14:41:43 +02:00
Maciej Suminski
6bfe6342fc
Simulator fixes for Windows
2016-08-11 14:41:41 +02:00
Maciej Suminski
6580a355ab
Strip 'stdout' & 'stderr' from ngspice log
2016-08-11 14:41:35 +02:00
Maciej Suminski
0da13052dd
SPICE_SIMULATOR interface allows to obtain different types of plots (mag, phase, real, imag)
2016-08-11 14:41:31 +02:00
Maciej Suminski
9f3324bac7
Changed the way ngspice is executed Previously it was run in a wxThread, but it did not allow to issue commands while the simulation is running. If you check ngspice shared library source code, then you will discover "bg_*" commands that executes commands in background, so the simulator still can be controlled.
2016-08-11 14:41:19 +02:00
Maciej Suminski
38042ac9e0
NGSPICE class minor cleanup
2016-08-11 14:41:17 +02:00
Maciej Suminski
ac17165947
Initial version of simulator probe tool
2016-08-11 14:41:11 +02:00
Maciej Suminski
a4868a0e5a
Minor fixes to debug output
2016-08-11 14:41:10 +02:00
Maciej Suminski
9ef2cb94bf
Simulation executes in a separate thread
2016-08-11 14:41:07 +02:00
Maciej Suminski
e72b54a6e0
Code cleanup
2016-08-11 14:41:07 +02:00
Maciej Suminski
9e2485ea97
SPICE_SIMULATOR: Code formatting & clean up
2016-08-11 14:41:07 +02:00
Tomasz Wlostowski
095af6e77a
wip
2016-08-11 14:41:01 +02:00
Tomasz Wlostowski
f1f69979e6
ngspice: something starts to work
2016-08-11 14:41:01 +02:00