Commit Graph

1646 Commits

Author SHA1 Message Date
rlar 39abfee774 subckt.c, #2/5 rename submod --> orig_modnames 2014-06-24 18:17:51 +02:00
rlar cb25ce757e subckt.c, #1/5 cleanup modtranslate() signature 2014-06-24 18:17:42 +02:00
rlar aa7a7606c7 avoid multiple declarations of controlled_exit(), add 'noreturn' attribute 2014-05-14 21:36:18 +02:00
rlar fbdea9be3d inpcom.c, inp_fix_inst_calls_for_numparam() rewrite for cleanup 2014-05-14 20:23:21 +02:00
rlar 6d30585a5e inpcom.c, inp_fix_inst_calls_for_numparam(), local scope for some vars 2014-05-14 19:42:48 +02:00
rlar 5862d1b297 inpcom.c, inp_fix_inst_calls_for_numparam(), avoid excess tfree() invocations 2014-05-14 19:16:13 +02:00
rlar e652dc40be inpcom.c, drop unused artifacts 2014-05-14 18:18:22 +02:00
rlar 7a6b569b3b inpcom.c, rewrite bizarre code in inp_get_params() 2014-05-14 18:15:00 +02:00
rlar 6f89395d8a fix commit: introduce OUTerrorf() and IFerrorf() 2014-05-07 20:06:00 +02:00
rlar cc235294ec lexical.c, change semantics of an ESCAPE in a given input `string'
now simply skip it.

presumably and in accordance to what the comments seems to suggest
  ESCAPE never was really meant to be read as '['
  but was replaced just to get it out of way deeper in the for loop
  where an ESCAPE starts an ancient mechanism to reenter
    interactive input via a terminals TIOCSTI capability
2014-04-15 21:16:50 +02:00
rlar cb75a749b8 lexical.c, avoid to read beyond end of `string' 2014-04-15 21:16:49 +02:00
rlar f42b5b16c7 lexical.c, simplify 2014-04-15 21:16:48 +02:00
rlar 8c7ae0d61c lexical.c, simplify using cp_readchar() 2014-04-15 21:16:46 +02:00
rlar 448099ef94 lexical.c, new function cp_readchar() for abstraction 2014-04-15 21:12:46 +02:00
rlar 9bd2cdfc7b modtranslate(), cleanup using tprintf() 2014-04-13 19:58:47 +02:00
rlar 7813f6cf6a cleanup, use tprintf() 2014-04-12 21:34:16 +02:00
rlar cc56c90b9d drop asprintf() 2014-04-12 21:02:31 +02:00
rlar 7aa454e5b4 rewrite, using tprintf() 2014-04-05 19:10:12 +02:00
rlar 1a0a00c9c2 inp.c, nicer printout of multi line error messages 2014-04-05 18:44:04 +02:00
rlar f26c1b71f9 introduce OUTerrorf() and IFerrorf()
a varargs variant of the older variants OUTerror() and IFerror()
2014-04-04 21:22:47 +02:00
rlar 0182f2f7ca swallow an unused format argument warning 2014-04-04 21:22:45 +02:00
Y.Niitsu 4de727f4a9 update bison generated files 2014-04-02 21:15:04 +02:00
Y.Niitsu 6e3f60c6bd frontend/parse.c, allow nested `indexing', for example foo[bar[n]]
.control
compose ex1 values 111 222 333
compose ex2 values 1 2 3
print ex1 ex2 ex1[ex2[1]]
.endc
2014-04-02 21:14:10 +02:00
rlar b6ed9a3620 bug fix, `#279 Problem when using a function to set initial value"
reported by Marcel Hendrix in
  http://sourceforge.net/p/ngspice/bugs/279/

"SPF_time" erroneously did match "time"

introduce a saver matcher for
  `v(' `i(' `temper' `time' and `hertz'
when checking for behavioural R,L,C devices
2014-04-01 21:17:00 +02:00
rlar 060257a468 inpcom.c, sharedlib, strip leading whitepace from circuit deck
this was traditionally done in inp_read() by readline(),
  and was missing for circuit decks passed by 'circarray'
2014-03-09 17:10:55 +01:00
h_vogt 8499ef0428 .option 'savecurrents' for storing all current of relevant devices 2014-02-07 22:47:09 +01:00
dwarning 461026f2b9 fix to use garbage collector with --enable-gc 2014-02-07 13:19:35 +01:00
h_vogt bdb54257c7 outitf.c: new option interp to plot interpolated raw file data
during transient analysis
2014-02-01 14:24:04 +01:00
h_vogt 0609d231c0 runcoms2.c: prevent crash after 'remcirc' if no circuit is loaded 2014-01-29 21:21:16 +01:00
rlar 66281cad4e inpcom.c: exclude command 'shell' from lower case letter transformation
reported by Dominique Michel
[Ngspice-users] gs is confused with the shell command

shell gs -dBATCH -dNOPAUSE -sDEVICE=png256 -sOutputFile="plot.png"
2014-01-19 17:14:13 +01:00
h_vogt 1f5de32512 global variable Infile_Path, which contains the
input netlist file path
2014-01-18 19:10:29 +01:00
h_vogt bf1fb3f105 inp.c: prevent crash upon if_inpdeck() returning NULL 2014-01-17 20:24:44 +01:00
rlar ed23c7e315 set X11 window title from `graph->plotname'
in response to a bug report by Dominique Michel
  "#272 no title in plots"
  http://sourceforge.net/p/ngspice/bugs/272/
2014-01-11 16:24:25 +01:00
h_vogt 74b32f392c inpcom.c: E, G source, improved search for 'vol' and 'cur'
in response to a bug report by Marlize Schoeman
  "#274 VCVS Exxxx name and node names do not allow VOL as text"
  http://sourceforge.net/p/ngspice/bugs/274/
2014-01-11 16:24:23 +01:00
rlar f2093b17e8 parseunit(), support 'T' for "Tera"
in response to a bug report by Andy Fierman
  "#273 T = Tera = 1e12 suffix is ignored when used in a parameter in a subcircuit."
  http://sourceforge.net/p/ngspice/bugs/273/
2014-01-11 16:24:21 +01:00
h_vogt d5b2460123 inp.c, inp2q.c improve error message
when we exit() in batch mode due to a missing model definition
2014-01-11 16:24:19 +01:00
rlar bb28578956 workaround, avoid batch termination when there are .model issues
these were introduced by commit
  "inp.c, evtinit.c: improved error message suggested by Calin Andrian"
and caused ngspice checks to fail unexpectedly
2014-01-11 16:24:17 +01:00
h_vogt bd1b4a2162 gnuplot.c: enable correct terminal for non MINGW/MSVC 2014-01-11 16:24:14 +01:00
h_vogt 23ffcbf7d1 variable.c: prevent buffer overflow by limiting variable output to BSIZE_SP characters 2014-01-11 16:24:11 +01:00
h_vogt dfbaeaea29 com_ghelp.c: add info on non-availability of help to console versions w/o X display. 2014-01-11 16:24:08 +01:00
dwarning 1e448f497d 1-f-code.c, correct the printout for noise generation 2014-01-02 09:54:01 +01:00
dwarning b535b43980 1-f-code.c, use fftw3 2014-01-02 09:54:00 +01:00
dwarning 9e01e1c384 com_fft.c, set hanning as default window 2014-01-02 09:53:58 +01:00
dwarning 38ad8f7602 com_fft.c, rename variable `tlen' --> `length' 2014-01-02 09:53:57 +01:00
dwarning dd290c1886 com_fft.c, correct array size and relay to specific array order for r2c transformation 2014-01-02 09:53:56 +01:00
dwarning 8ed75d166d com_fft.c, use FFTW3 for com_fft() and com_psd() 2014-01-02 09:53:54 +01:00
dwarning c61e1bc8c6 fftext.c, move the Bourke FFT code to fftext.c (as a backup) 2014-01-02 09:53:52 +01:00
dwarning cd8aa1ee04 cmath4.c, com_fft.c, cleanup 2014-01-02 09:51:41 +01:00
dwarning f989219f6f cmath4.c, com_fft.c, rename `size' --> `N' and `mm' --> `M' 2014-01-02 09:51:39 +01:00
h_vogt 0e2fc3ceef inpcom.c: allow node names and .func parameters having
equal string representation
2014-01-02 09:33:33 +01:00
h_vogt e2f3ea24c0 main.c, suppress progress report when '-o' is used to redirect output 2014-01-02 09:33:31 +01:00
h_vogt a717fd01ab inpcom.c: enable .include with $end-of-line in .control section 2014-01-02 09:33:28 +01:00
rlar d225c4f958 xpressn.c, introduce fortran style nint() rounding function 2014-01-02 09:33:21 +01:00
rlar a088a6e0e6 subckt.c, fix .model processing (scope) 2014-01-02 09:33:18 +01:00
h_vogt 59de942bdf enable parameter replacement in R, L, C lines, if equation is
without {} and not in a subcircuit
2014-01-02 09:33:16 +01:00
h_vogt 8dbefe2153 inpcom.c: allow proper 'temper' substitution
if device name and parameter name are the same,
or if parameter name is the last token in the line.
2014-01-02 09:33:09 +01:00
h_vogt bdcd7dc1a7 inp.c: evaluate for 'temper' only the models which have
been entered into the hash table ckt->MODnameHash
2014-01-02 09:33:07 +01:00
h_vogt 75eee691c4 inpcom.c remove bug: parens around equation h, f
add equation + temper capability to gain of F-Source
2014-01-02 09:33:03 +01:00
h_vogt 606c98904d inpcom.c: H Source with equation and temper in transresistance 2014-01-02 09:33:01 +01:00
dwarning c8f5d49ddd implement CKTsoaCheck() 2014-01-02 09:32:34 +01:00
rlar e2292cc5c4 inpcom.c, drop cp_tildexpand() in expand_this(), inp_pathresolve_at() shall do this 2014-01-02 09:32:29 +01:00
rlar 71fc51871e inpcom.c, rewrite .lib reading
use canonical file names to remember known .lib files
remember their directories in `habitat'
use inp_pathresolve_at() to find .lib files with regard to `searchpath' and current directory
2014-01-02 09:32:27 +01:00
rlar f2d3c9f122 inpcom.c, recurse expand_section_ref() 2014-01-02 09:32:25 +01:00
rlar 366d79b9b9 inpcom.c, cleanup 2014-01-02 09:32:24 +01:00
rlar 0420c0604b inpcom.c, whitespace cleanup 2014-01-02 09:32:22 +01:00
rlar 8fe86bb1c9 inpcom.c, reorder 2014-01-02 09:32:20 +01:00
rlar 0a2f5d2e55 inpcom.c, abstraction, introduce expand_section_ref() 2014-01-02 09:32:19 +01:00
rlar 6c30ad1b1e inpcom.c, simplify `.include' file processing using inp_pathresolve_at() 2014-01-02 09:32:17 +01:00
rlar 196102ee88 inpcom.c, introduce inp_pathresolve_at() 2014-01-02 09:32:15 +01:00
rlar 51bbd8c4d4 inpcom.c, introduce inp_pathresolve(), rewrite inp_pathopen() using this 2014-01-02 09:32:11 +01:00
h_vogt 9959030765 inpcom.c, for mingw absolute pathnames may begin with /d/
allow this when variable 'mingwpath' is set in .spinit
2014-01-02 09:32:08 +01:00
h_vogt 85ddc5b6db inpcom.c, remove variable "sourcefile" and references to "sourcefile"
this will no longer be required for access to input file residing
in the executable's directory
2014-01-02 09:32:06 +01:00
rlar 9b4238ed04 inpcom.c, fix inp_pathopen(), always try to fopen() relative to the current working directory first 2014-01-02 09:32:03 +01:00
rlar 0ce23e6f10 inpcom.c, fix inp_pathopen(), relative path shall be expanded regarding "sourcepath" 2014-01-02 09:31:58 +01:00
rlar 7524882f67 inpcom.c, simplify using is_plain_filename(), fix incorrect comments 2014-01-02 09:31:56 +01:00
rlar e0c398024f inpcom.c, implement is_absolute_pathname() and is_plain_filename() 2014-01-02 09:31:55 +01:00
h_vogt bb121fe903 inp.c, evtinit.c: improved error message
suggested by Calin Andrian
2014-01-02 09:31:23 +01:00
h_vogt 780ccbfb3c prevent crash, if due to input bug ckt is not created,
reported by  Andrian
2014-01-02 09:31:21 +01:00
h_vogt 8ad6bd209d replacements for functions missing in the msvc world 2014-01-02 09:31:10 +01:00
rlar 492f1f006c numparam, almost full precision for stringified double float numbers 2014-01-02 09:25:48 +01:00
rlar 6a2060e472 xpressn.c, drop initkeys() 2013-12-31 16:42:06 +01:00
rlar 7463410a5e xpressn.c, drop "AND OR NOT DIV MOD DEFINED" keywords 2013-12-31 16:42:05 +01:00
rlar 6b1363dcf7 xpressn.c, use C strings for the arguments of `keywords()' 2013-12-31 16:42:04 +01:00
rlar a855a19d2c xpressn.c, drop '&' and '|' operators, (we have '&&' and '||') 2013-12-31 16:42:04 +01:00
rlar 719b5e5c20 inpcom.c, exclude currently unused functions 2013-12-31 16:42:03 +01:00
rlar df0d1826ca inpcom.c, drop ternary_fcn code in inpcom.c, the extended "formula" shall process ternary expressions 2013-12-31 16:41:36 +01:00
rlar ef3580d590 xpressn.c, whitespace cleanup 2013-12-31 16:41:35 +01:00
rlar 1ac45bfd57 xpressn.c, implement a?b:c in the "formula" parser 2013-12-31 16:41:34 +01:00
rlar 1b959e6a50 xpressn.c, drop XFU_V
probably accidentally introduced in commit

> Author: h_vogt <h_vogt>
> Date:   Sun Feb 7 11:27:59 2010 +0000
>
>     improved numparam error message
2013-12-31 16:41:34 +01:00
rlar 9cb20e97d0 xpressn.c, use enums instead of literals 2013-12-31 16:41:33 +01:00
rlar 297778127b xpressn.c, drop "Defd" enum, to be incorporated into a bigger enum 2013-12-31 16:41:32 +01:00
rlar 76c7cd6fbd xpressn.c, fix semantics of `int(x)' and remove dangerous macros
int(x) most probably shall be trunc(x) instead of floor(x)
  note trunc(x) was #defined beeing floor(x)
  note ln(x) was #defined beeing log(x)
2013-12-31 16:41:32 +01:00
rlar 2854fa71d4 fix an endless loop waiting for y/n when the input is at EOF
reported by Calin Andrian
  Subject: [Ngspice-devel] Invaild number bug
2013-12-31 16:41:31 +01:00
rlar 467eb58244 xpressn.c, fix semantics of '&&' and '||'
these shall interpret a value as a bool according to (value != 0)
and these shall evaluate to either 1.0 or 0.0
2013-12-31 16:41:30 +01:00
rlar f6d610a1b6 xpressn.c, whitespace cleanup 2013-12-31 16:41:30 +01:00
rlar 0a42a19b02 xpressn.c, fix `truth' for ternary_fcn()
0.0 is `false', everything else is `true'
2013-12-31 16:41:29 +01:00
rlar 589ded417a update bison generated files 2013-12-31 16:41:29 +01:00
rlar b32ae9f79b .control and `B' parser, fix precedence of '-' versus '^'
-2^2 shall be -(2^2) instead of (-2)^2
2013-12-31 16:41:28 +01:00
h_vogt ad5c09a865 remove unused code 2013-12-31 16:41:27 +01:00
rlar a235b46795 inpcom.c, add missing condition `!comfile' for .title and .end processing 2013-12-31 16:41:25 +01:00