From b3ffbd62587828bd12b67657ece93a3de4885dc8 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Wed, 1 Feb 2023 00:37:44 +0000 Subject: [PATCH] Don't include unconnected nets in signals list. Fixes https://gitlab.com/kicad/code/kicad/issues/4961 --- eeschema/sim/sim_plot_frame.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/eeschema/sim/sim_plot_frame.cpp b/eeschema/sim/sim_plot_frame.cpp index 77d4092626..a8970853ca 100644 --- a/eeschema/sim/sim_plot_frame.cpp +++ b/eeschema/sim/sim_plot_frame.cpp @@ -562,7 +562,9 @@ void SIM_PLOT_FRAME::StartSimulation( const wxString& aSimCommand ) if( simulatorLock.owns_lock() ) { wxBusyCursor toggle; + wxString unconnected = wxString( wxS( "unconnected-(" ) ); + unconnected.Replace( '(', '_' ); // Convert to SPICE markup m_signals.clear(); // Add voltages @@ -571,7 +573,7 @@ void SIM_PLOT_FRAME::StartSimulation( const wxString& aSimCommand ) // netnames are escaped (can contain "{slash}" for '/') Unscape them: wxString netname = UnescapeString( net ); - if( netname != "GND" && netname != "0" ) + if( netname != "GND" && netname != "0" && !netname.StartsWith( unconnected ) ) m_signals.push_back( wxString::Format( "V(%s)", netname ) ); }