Corrected the ext2sim output and extresist to properly handle
2-terminal devices without complaining. The previous handling seemed to be technically correct other than spitting out warnings about missing terminals.
This commit is contained in:
parent
7b485efa9b
commit
e72f85fd10
|
|
@ -1169,22 +1169,28 @@ simdevVisit(dev, hc, scale, trans)
|
|||
}
|
||||
}
|
||||
|
||||
if (is_subckt && subnode)
|
||||
if (dev->dev_class != DEV_DIODE && dev->dev_class != DEV_NDIODE &&
|
||||
dev->dev_class != DEV_PDIODE)
|
||||
{
|
||||
/* As a general policy on subcircuits supporting extresist, */
|
||||
/* output the subcircuit node as the last port of the */
|
||||
/* subcircuit definition. */
|
||||
putc(' ', esSimF);
|
||||
simdevSubstrate(hierName, subnode->efnode_name->efnn_hier,
|
||||
dev->dev_type, 0.0, FALSE, esSimF);
|
||||
}
|
||||
if (is_subckt && subnode)
|
||||
{
|
||||
/* As a general policy on subcircuits supporting extresist, */
|
||||
/* output the subcircuit node as the last port of the */
|
||||
/* subcircuit definition, *except* for the use of the 'x' */
|
||||
/* device type for diodes. */
|
||||
|
||||
/* Support gemini's substrate comparison */
|
||||
else if (esFormat == LBL && subnode)
|
||||
{
|
||||
putc(' ', esSimF);
|
||||
simdevSubstrate(hierName, subnode->efnode_name->efnn_hier,
|
||||
putc(' ', esSimF);
|
||||
simdevSubstrate(hierName, subnode->efnode_name->efnn_hier,
|
||||
dev->dev_type, 0.0, FALSE, esSimF);
|
||||
}
|
||||
|
||||
/* Support gemini's substrate comparison */
|
||||
else if (esFormat == LBL && subnode)
|
||||
{
|
||||
putc(' ', esSimF);
|
||||
simdevSubstrate(hierName, subnode->efnode_name->efnn_hier,
|
||||
dev->dev_type, 0.0, FALSE, esSimF);
|
||||
}
|
||||
}
|
||||
|
||||
GeoTransRect(trans, &dev->dev_rect, &r);
|
||||
|
|
@ -1228,7 +1234,7 @@ simdevVisit(dev, hc, scale, trans)
|
|||
/* Output source and drain attributes */
|
||||
if (source->dterm_attrs)
|
||||
fprintf(esSimF, " s=%s", source->dterm_attrs);
|
||||
if (drain->dterm_attrs)
|
||||
if ((source != drain) && drain->dterm_attrs)
|
||||
fprintf(esSimF, " d=%s", drain->dterm_attrs);
|
||||
|
||||
/* Output length, width, and position as attributes */
|
||||
|
|
|
|||
|
|
@ -1322,8 +1322,19 @@ ResFixUpConnections(simDev, layoutDev, simNode, nodename)
|
|||
layoutDev->rd_inside.r_xbot, layoutDev->rd_inside.r_ybot,
|
||||
nodename);
|
||||
}
|
||||
|
||||
if (simDev->source == simNode)
|
||||
{
|
||||
/* Check for devices with only one terminal. If it was cast as drain, */
|
||||
/* then swap it with the source so that the code below handles it */
|
||||
/* correctly. */
|
||||
|
||||
if (layoutDev->rd_fet_source == NULL && layoutDev->rd_fet_drain != NULL)
|
||||
{
|
||||
layoutDev->rd_fet_source = layoutDev->rd_fet_drain;
|
||||
layoutDev->rd_fet_drain = (struct resnode *)NULL;
|
||||
}
|
||||
|
||||
if (simDev->drain == simNode)
|
||||
{
|
||||
if (((source = layoutDev->rd_fet_source) != NULL) &&
|
||||
|
|
|
|||
Loading…
Reference in New Issue