One update to this which is somewhat unrelated to the problem. I got this technique to work with gEDA+LTspice. I just made model-name="jj params: Ic=35uA Rq=2" and then the spice-sdb netlister sticks it in there. So now I just need to create a variant of spicepp which can render this spice code berkeley spice compliant.

Dave


David Grant wrote:

I want to be able to do something like this:

X1 0 1 jj params: Ic=35uA Rq=2
X2 0 1 jj
.subckt jj n1 n2
B1 n1 n2 I=f(Ic, Rq)
blah blah
.param Ic=30uA Rq=1
.ends jj

This is basically totally LTspice syntax, but I'd like to be able to do this with just berkely spice3 or some other open source program like tclspice. Or if it is possible, to have the spice-compatible netlist generated from a schematic specifying what is shown above.

Is there any method to do this currently?

I've looked at spicepp but it doesn't help me. Although the idea is the same. In my case though, to do this automatically, I need two subcircuits to be generated, one with the default params, the other with the params specified at the X? line. Then I need to have the .param line substituted into the B? line current function I=f(Ic, Rq).

I guess what I need is a .model. But berkeley spice doesn't support that. I guess gnucap would be a good option perhaps. (yes, I am doing josephson junctions, BTW)



--
David J. Grant
http://www.davidgrant.ca:81

begin:vcard
fn:David Grant
n:Grant;David
adr:;;;Richmond;BC;;Canada
email;internet:[EMAIL PROTECTED]
x-mozilla-html:TRUE
url:http://www.davidgrant.ca:81
version:2.1
end:vcard

Reply via email to