Spice simulator: prefix reference with device type only when necesary
Fixes: lp:1767271 * https://bugs.launchpad.net/kicad/+bug/1767271 Fixes: lp:1700853 * https://bugs.launchpad.net/kicad/+bug/1700853
This commit is contained in:
parent
986b90424b
commit
bc67d1ad8c
|
@ -99,8 +99,12 @@ bool NETLIST_EXPORTER_PSPICE::Format( OUTPUTFORMATTER* aFormatter, unsigned aCtl
|
||||||
if( !item.m_enabled )
|
if( !item.m_enabled )
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
// Save the node order
|
// Add a character determining the device type if the original reference
|
||||||
aFormatter->Print( 0, "%c%s ", item.m_primitive, (const char*) item.m_refName.c_str() );
|
// would result in a different device type
|
||||||
|
if( item.m_primitive != item.m_refName[0] )
|
||||||
|
aFormatter->Print( 0, "%c", item.m_primitive );
|
||||||
|
|
||||||
|
aFormatter->Print( 0, "%s ", (const char*) item.m_refName.c_str() );
|
||||||
|
|
||||||
size_t pspiceNodes = item.m_pinSequence.empty() ? item.m_pins.size() : item.m_pinSequence.size();
|
size_t pspiceNodes = item.m_pinSequence.empty() ? item.m_pins.size() : item.m_pinSequence.size();
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue