Holger Vogt
44b8498d63
prevent a crash when e,g,f,h sources do not have enough paramaters.
5 years ago
Holger Vogt
d0a8e6ac51
update to the limit function for ps compatibility.
The output will stay between the two limits given.
Tere is no prescription which of the two is upper
or lower.
This function will not solve all PS-Spice
compatible model convergence issues. We better look
for a built-in function with smooth, steadily
differentiable corners.
5 years ago
Vogt
bb8cdb2e2d
enable the use of either single or double quotes
for file path names (was mixed up, becaus isquote()
aknowledges both types).
5 years ago
dwarning
03cd512e7f
separate and correct capacitor charge formula transformation
5 years ago
Holger Vogt
95754d29c1
Introduce variacle 'plainlet' which allow simple copying
of vectors, even if the right hand side vector name
contain forbidden characters (like math characters).
set plainlet
let newvec = v(/out)
unset plainlet
5 years ago
dwarning
450ec47a3e
rm unused quote.h in vngspice_fftw
5 years ago
Holger Vogt
aa0d0abe34
Fix a bug in the limit() function (PSPICE compat mode)
5 years ago
Holger Vogt
9276f9fb0e
Use the pwl LIMIT=TRUE flag when replacing
G1 2 3 TABLE ... or E2 4 5 TABLE ... by code model pwl
5 years ago
Holger Vogt
d06ff2abab
New variable 'plainwrite' added. Allows 'write' with node names
containing characters like + - /. Function are the disabled.
This replaces the automatic selection of this mode by compat flags,
which is not transparent enough to the user.
6 years ago
Holger Vogt
36e2a9af4d
Add variable 'plainplot' to allow plotting without
function support, but with node names incl chatacters like + - /.
Flag to command 'plot' is renamed to plainplot.
Error message added if vector not found.
Example file added.
6 years ago
Holger Vogt
b76ac6be1c
Add writing all vectors if compat mode eg or ki is selected.
6 years ago
Holger Vogt
f0090508b0
If new parameter 'plain' is added to the 'plot' command,
all expression handling is skipped, vectors are plotting as is.
This allows nodes names with vectors like v(+vs) or /out
to be plotted without need resorting to double quotes.
6 years ago
Holger Vogt
84d3d8c143
Don't add v(...) around output vector if compat mode 'eg' is set.
6 years ago
Holger Vogt
c90230b43f
If the compatibility flags ki or eg are set, the 'write' command
will not use function parsing and evaluation, but simply plot
the listed vectors. vec1 vs vec2 is also not supported.
This option is useful if node names vs+ or /mynode are used and
have to be written into a raw file, as may be used by KiCad or EAGLE.
6 years ago
Holger Vogt
19a688513c
add compatibility mode eg for EAGLE
clarify mode a for 'whole netlist' and ll for 'all'
6 years ago
Holger Vogt
dd86bdee46
Enlarge the buffer size for command 'listing' from 512 to 4096 bytes.
6 years ago
Holger Vogt
3e98cecd56
enable paths with spaces for finding 'spinit'
6 years ago
Holger Vogt
c67da190ef
If function 'db' is evaluated, set
v_type to SV_DB.
6 years ago
Holger Vogt
97db844944
Prevent raw file entries (by the 'write' command) like
6 i(i(v_vsupply2)) current
6 years ago
Holger Vogt
f49922c1f1
If a new vector is created by the functions cph or ph,
its type should be 'phase', not voltage. Thus prevent
raw file entries (created by the 'write' command like
4 v(cph(vout2)) voltage
6 years ago
dwarning
f12dfc6e7b
prevent garbage output of X11 plotting function
6 years ago
Holger Vogt
7360d8aa66
Fix a typo
6 years ago
Holger Vogt
4796face12
Make message more verbose by printing the scale value
6 years ago
Holger Vogt
28861739f8
allow writing character '%'
6 years ago
Holger Vogt
af99beb6a2
Allow simple copying from start time to end time
6 years ago
Holger Vogt
013c74918f
Command 'cutout': Don't add the scale vector to nv->v_scale.
So the new plot with its vectors copied resembles the old plot.
6 years ago
Holger Vogt
a836f81d62
This is a quick fix to the Windows printing function.
Tested with pdf and a color laser printer.
Still some bugs: the grid needs to be fixed.
6 years ago
Holger Vogt
51df9aaa55
remove non ascii character §, which leads to compiler warnings
6 years ago
Holger Vogt
fdc143ce16
Add a limit capability to the code model aswitch
Example switch-oscillators_inc.cir showed currents up to 3GA
6 years ago
Holger Vogt
4bcacb310d
enable XSPICE %vnam in subcircuits.
The token following after %vnam has to be
tranlated as an instance during subcircuit expansion.
6 years ago
Holger Vogt
14ef4e74ec
Add PSPICE compatible ISWITCH
Translates iswitch either to csw or to aswitch models
6 years ago
Holger Vogt
2f1d3df8c7
add a Spectre compatibility mode
6 years ago
Holger Vogt
990d87bf1c
replace gettok by gettok_node to ignore parentheses when reading
a .model line in the altermod ... file ... command.
6 years ago
Holger Vogt
b0a790a463
proper size_t to int conversion
6 years ago
Holger Vogt
8ea8ddcc03
simplify the previous commit, single step warp if multibyte utf-8 character
6 years ago
Holger Vogt
f911758e4b
X11: re-enable writing text to a graph if libxft is used
6 years ago
Holger Vogt
445c6f2d32
fix a bug that occurs when xspice is not selected
missing function parameter has been introduced in previous commit
6 years ago
Holger Vogt
602baf68e6
spice2g6 allows to omit the poly(n) statement, if the
polynomial is one-dimensional (n==1).
For compatibility with the XSPIXE code, we have to add
poly(1) appropriately.
6 years ago
Holger Vogt
60dfe836f4
If ps is enabled, .dc TEMP -15 75 5 will have been
modified to .dc (TEMPER) -15 75 5.
So we repair it here with a preliminary fix.
6 years ago
Holger Vogt
ca27319213
no forcing lower-case letters for command 'cd'
6 years ago
Holger Vogt
a0389bb547
In PS compatibility mode:
In subcircuit .subckt and X lines with 'params:' statement
replace comma separator by space. Do nothing if comma is inside of {}.
6 years ago
Holger Vogt
26a4a32b8b
avoid some compiler warnings 'referencing a NULL pointer'
6 years ago
Holger Vogt
458411b2e1
more precise freeing the wordlist, depending on exit point
6 years ago
Holger Vogt
e3aad7849c
remove vceo= and icrating= from bjt model cards
6 years ago
Holger Vogt
23ceaabf83
fix a memory leak
Reported in bug report 504 by Ferdy
6 years ago
Holger Vogt
a04c909a23
Don't add copied scale vector as new vector, but as new scale vector,
thus preventing crash after pushing X11 'Hardcopy' twice or
pushing 'quit' after 'Hardcopy'.
Scale vector was deleted two times, then crashimg ngsoice.
6 years ago
Holger Vogt
c68940712d
prevent writing beyond end of buffer
6 years ago
Holger Vogt
ebb1e953fe
Streamline the compatibility flag generation
6 years ago
Holger Vogt
f03a32287f
If 'set ngbehavior=ki' in .spiceinit or flag 'kicad' on the plot line:
Add " around vector names containing character /
Numerical ivision in plot line then requires spaces around /
6 years ago
Holger Vogt
c112279555
new compatibility handling with struct compat newcompat:
simplify the compatibility handling, better readability
make it easily extendable
add new flag 'ki' for KiCad compatibility
6 years ago