Fix Bug #1513556 (missing components, when pspice specific fields Spice_Netlist_Enabled or Spice_Node_Sequence have no value.)
This commit is contained in:
parent
2f92087bac
commit
2cfa79e52f
|
@ -185,9 +185,6 @@ bool NETLIST_EXPORTER_PSPICE::WriteNetlist( const wxString& aOutFileName, unsign
|
||||||
{
|
{
|
||||||
wxString netlistEnabled = netlistEnabledField->GetText();
|
wxString netlistEnabled = netlistEnabledField->GetText();
|
||||||
|
|
||||||
if( netlistEnabled.IsEmpty() )
|
|
||||||
break;
|
|
||||||
|
|
||||||
if( netlistEnabled.CmpNoCase( disableStr ) == 0 )
|
if( netlistEnabled.CmpNoCase( disableStr ) == 0 )
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
@ -201,37 +198,39 @@ bool NETLIST_EXPORTER_PSPICE::WriteNetlist( const wxString& aOutFileName, unsign
|
||||||
wxString nodeSeqIndexLineStr = spiceSeqField->GetText();
|
wxString nodeSeqIndexLineStr = spiceSeqField->GetText();
|
||||||
|
|
||||||
// Verify Field Exists and is not empty:
|
// Verify Field Exists and is not empty:
|
||||||
if( nodeSeqIndexLineStr.IsEmpty() )
|
if( !nodeSeqIndexLineStr.IsEmpty() )
|
||||||
break;
|
|
||||||
|
|
||||||
// Create an Array of Standard Pin Names from part definition:
|
|
||||||
stdPinNameArray.Clear();
|
|
||||||
|
|
||||||
for( unsigned ii = 0; ii < m_SortedComponentPinList.size(); ii++ )
|
|
||||||
{
|
{
|
||||||
NETLIST_OBJECT* pin = m_SortedComponentPinList[ii];
|
|
||||||
|
|
||||||
if( !pin )
|
// Create an Array of Standard Pin Names from part definition:
|
||||||
continue;
|
stdPinNameArray.Clear();
|
||||||
|
|
||||||
stdPinNameArray.Add( pin->GetPinNumText() );
|
for( unsigned ii = 0; ii < m_SortedComponentPinList.size(); ii++ )
|
||||||
}
|
|
||||||
|
|
||||||
// Get Alt Pin Name Array From User:
|
|
||||||
wxStringTokenizer tkz( nodeSeqIndexLineStr, delimeters );
|
|
||||||
|
|
||||||
while( tkz.HasMoreTokens() )
|
|
||||||
{
|
|
||||||
wxString pinIndex = tkz.GetNextToken();
|
|
||||||
int seq;
|
|
||||||
|
|
||||||
// Find PinName In Standard List assign Standard List Index to Name:
|
|
||||||
seq = stdPinNameArray.Index(pinIndex);
|
|
||||||
|
|
||||||
if( seq != wxNOT_FOUND )
|
|
||||||
{
|
{
|
||||||
pinSequence.push_back( seq );
|
NETLIST_OBJECT* pin = m_SortedComponentPinList[ii];
|
||||||
|
|
||||||
|
if( !pin )
|
||||||
|
continue;
|
||||||
|
|
||||||
|
stdPinNameArray.Add( pin->GetPinNumText() );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Get Alt Pin Name Array From User:
|
||||||
|
wxStringTokenizer tkz( nodeSeqIndexLineStr, delimeters );
|
||||||
|
|
||||||
|
while( tkz.HasMoreTokens() )
|
||||||
|
{
|
||||||
|
wxString pinIndex = tkz.GetNextToken();
|
||||||
|
int seq;
|
||||||
|
|
||||||
|
// Find PinName In Standard List assign Standard List Index to Name:
|
||||||
|
seq = stdPinNameArray.Index(pinIndex);
|
||||||
|
|
||||||
|
if( seq != wxNOT_FOUND )
|
||||||
|
{
|
||||||
|
pinSequence.push_back( seq );
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue