PSpice And Spice3/XSpice
There are some differences between PSpice syntax and Spice3/XSpice spice engines. In many cases PSpice specific syntax can be easily converted to Spice3/XSpice.
Voltage and Current Controlled switches
PSpice uses Von and Voff, Ion, Ioff. Spice uses Vth and Vhyst. The conversion is obvious!
Controlled Sources:
PSpice uses a different syntax then Spice3/XSpice for function controlled sources. Spice3/XSpice controlled sources all use the "B source".
The XSpice syntax is:
B_a_source_name node_out1 node_out2 v=V(net3, net4)*exp(net4)…
Or, for a current output:
B_a_source_name node_out1 node_out2 i=V(net3, net4)*exp(net4)…
Note the first letter (reference designator) must be a B.
The equivalent PSpice format is:
H_ a_source_name node_out1 node_out2 VALUE={V(net3, net4)*exp(net4)…}
e.g. remove the “{}” , replace the H/G/F/E by B, replace VALUE by v or i.
SuperSpice should convert this automatically, but it might be well to check.
Power Function:
PSpice also uses pwr(x, y) as its syntax for xy. This must be converted to x^y
If - Else Expressions
PSpice if-else constructs are not directly supported in Spice3/Spice. They can be converted as exampled here:
B_ifelseconverted 2 1 v= U(v(3) - v(4)) * (expression1) + (1 - U(v(3) - v(4)) * expression2
U(t) = 1 for t > 0, and 0 otherwise. The above B source therefore picks out expresion1 or expression2 depending on whether v(3)>v(4).
Source Node Name Brackets
Some legacy models for E, H, F H type sources have syntax such as
E1 1 2 (4,6) 10
The brackets must be removed, with the comma replaced by a space, as:
E1 1 2 4 6 10
this conversion not apply to brackets in POLY() brackets.
Mosfet Lambda
For mosfet Level=3, Spice3/XSpice does not use the LAMBDA parameter, hence it is ignored. L and W are also not in the .model description, but are passed through from the spice line for that component.
SuperSpice accepts W and L either in the .model, or on the spice line that is set from the schematic. Schematic values override the model values.
.Subckt Parameters
Support for PSpice ".subckt" parameter passing is provided. Also PSpice internal .param lines are supported.
Further information is at Subckts
Global Nodes
Global node names are not supported.
Other Variations:
Some other vendor Spice's have netlists that also have syntax not compatible to Spice3/XSpice. e.g. ".param" ".global" etc. In most cases these netlists can be modified so that SuperSpice can run them. There is a Unix pearl script file, currently at HSpice to Spice3 Converter, curtsey of John Sheahan, john@reptechnic.com.au that converts HSpice to Spice3 syntax. However, this has not been tested by AnaSoft.
Please contact AnaSoft for more information in converting HSpice files, such as .lib statements. Usually, AnaSoft can do this conversion, and will do so free of charge.