[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: gEDA-user: ngspice subckt problems
On Thursday 14 August 2008, Christoph Lechner wrote:
> I'm just trying to use my spice model in ngspice.
> LTspice/SwitcherCad from Linear Technology runs it like a
> charm.
>
> If I run ngspice I get some error messages:
> Too few parameters for subcircuit type "12at7" (instance:
> x102) Too few parameters for subcircuit type "12at7"
> (instance: x101)
One of the problems with Spice format simulators is that they
are all different.
It all goes back to Berkeley Spice-2 -- then deviates from
there. Every derivative of Spice has developed in its own way.
One adds a feature, and another adds the feature too, but a
little different. Every new feature makes some nuance that
used to work not work. Keep this up for 30 years .....
The makers of commercial simulators can afford to hire a bunch
of programmers to chase and clone the competition's new
features. The free ones don't have the resources for this,
unless users step in.
What you have is a file written with a bunch of those
proprietary extensions.
At a glance I see ...
-- the semicolon
-- ".param" statement
-- passing parameters to a subckt
-- the syntax for defining the default subckt parameters
-- addition of models
-- the existance of behavioral expressions
-- syntax differences for the behavioral expressions
So, fix one, you still have a dozen to go.
This is one of the reasons the experts are pushing for a change
away from the Spice format. Still, we have lots of legacy
code.
If you want to use Gnucap, I will help you make it work. It
will help me, by having a set of real files that somebody is
using.
> The background of why I now want to use ngspice is that I
> want to play with the parameters a little bit to get out the
> maximum possible output voltage swing. (This circuit is
> intended for scope tube deflection.) => Lots of simulation
> runs.
> So one needs some sort of scriptable spice environment, for
> example a UNIX command line program :)
That's another place where they are all different.
NGspice doesn't offer much in this regard. Gnucap offers much
more in being scriptable and ability to play with parameters.
Gnucap lets you make arbitrary changes to the circuit
interactively, so doing a bunch of "what-if's" is actually very
easy. It also will give you a lot more info about your
circuit, but only if you ask.
_______________________________________________
geda-user mailing list
geda-user@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-user