Handle Spice_Netlist_Enabled attribute in Spice netlist exporter
Fixes: lp:1630502 * https://bugs.launchpad.net/kicad/+bug/1630502
This commit is contained in:
parent
efdfaebf62
commit
26ee676278
|
@ -89,6 +89,9 @@ bool NETLIST_EXPORTER_PSPICE::Format( OUTPUTFORMATTER* aFormatter, unsigned aCtl
|
||||||
|
|
||||||
for( const auto& item : m_spiceItems )
|
for( const auto& item : m_spiceItems )
|
||||||
{
|
{
|
||||||
|
if( !item.m_enabled )
|
||||||
|
continue;
|
||||||
|
|
||||||
aFormatter->Print( 0, "%c%s ", item.m_primitive, (const char*) item.m_refName.c_str() );
|
aFormatter->Print( 0, "%c%s ", item.m_primitive, (const char*) item.m_refName.c_str() );
|
||||||
|
|
||||||
// Pins to node mapping
|
// Pins to node mapping
|
||||||
|
|
|
@ -151,6 +151,9 @@ void NETLIST_EXPORTER_PSPICE_SIM::writeDirectives( OUTPUTFORMATTER* aFormatter,
|
||||||
for( const auto& current :
|
for( const auto& current :
|
||||||
NETLIST_EXPORTER_PSPICE_SIM::GetCurrents( (SPICE_PRIMITIVE) item.m_primitive ) )
|
NETLIST_EXPORTER_PSPICE_SIM::GetCurrents( (SPICE_PRIMITIVE) item.m_primitive ) )
|
||||||
{
|
{
|
||||||
|
if( !item.m_enabled )
|
||||||
|
continue;
|
||||||
|
|
||||||
/// @todo is it required to switch to lowercase
|
/// @todo is it required to switch to lowercase
|
||||||
aFormatter->Print( 0, ".save %s\n",
|
aFormatter->Print( 0, ".save %s\n",
|
||||||
(const char*) GetSpiceVector( item.m_refName, SPT_CURRENT, current ).c_str() );
|
(const char*) GetSpiceVector( item.m_refName, SPT_CURRENT, current ).c_str() );
|
||||||
|
|
Loading…
Reference in New Issue