51 unsigned aNetlistOptions,
REPORTER* aReporter )
56 if( !
ReadyToNetlist(
_(
"Exporting netlist requires a fully annotated schematic." ) ) )
64 bool executeCommandLine =
false;
66 wxString fileName = aFullFileName;
108 executeCommandLine =
true;
113 wxFileName tmpFile = fileName;
115 fileName = tmpFile.GetFullPath();
118 executeCommandLine =
true;
138 prj_dir = prj_dir.SubString( 0, prj_dir.Len() - 2 );
145 fileName, aFullFileName,
150 wxArrayString output, errors;
151 int diag = wxExecute( commandLine, output, errors,
m_exec_flags );
158 msg.Printf(
_(
"Command error. Return code %d." ), diag );
167 if( output.GetCount() )
169 for(
unsigned ii = 0; ii < output.GetCount(); ii++ )
173 if( errors.GetCount() )
175 for(
unsigned ii = 0; ii < errors.GetCount(); ii++ )
211 if(
erc.TestDuplicateSheetNames(
false ) > 0 )
213 if( !
IsOK(
this,
_(
"Error: duplicate sheet names. Continue?" ) ) )
static const ADVANCED_CFG & GetCfg()
Get the singleton instance's config, which is shared by all consumers.
virtual void ExpressMail(FRAME_T aDestination, MAIL_T aCommand, std::string &aPayload, wxWindow *aSource=nullptr)
Send aPayload to aDestination from aSource.
Generate a netlist compatible with Allegro.
An abstract class used for the netlist exporters that Eeschema supports.
virtual bool WriteNetlist(const wxString &aOutFileName, unsigned aNetlistOptions, REPORTER &aReporter)
Write to specified output file.
static wxString MakeCommandLine(const wxString &aFormatString, const wxString &aNetlistFile, const wxString &aFinalFile, const wxString &aProjectDirectory)
Build up a string that describes a command line for executing a child process.
Generate a netlist compatible with CADSTAR.
Generate the KiCad netlist format supported by Pcbnew.
void Format(OUTPUTFORMATTER *aOutputFormatter, int aCtl)
Output this s-expression netlist into aOutputFormatter.
Generate a netlist compatible with OrCAD.
Generate a netlist compatible with PADS.
Generate a generic XML based netlist file.
A singleton reporter that reports to nowhere.
virtual const wxString GetProjectPath() const
Return the full path of the project.
A pure virtual class used to derive REPORTER objects from.
virtual REPORTER & ReportHead(const wxString &aText, SEVERITY aSeverity=RPT_SEVERITY_UNDEFINED)
Places the report at the beginning of the list for objects that support ordering.
virtual REPORTER & ReportTail(const wxString &aText, SEVERITY aSeverity=RPT_SEVERITY_UNDEFINED)
Places the report at the end of the list, for objects that support report ordering.
virtual REPORTER & Report(const wxString &aText, SEVERITY aSeverity=RPT_SEVERITY_UNDEFINED)=0
Report a string with a given severity.
Holds all the data relating to one schematic.
SCH_SHEET_LIST Hierarchy() const override
Return the full schematic flattened hierarchical sheet list.
void DefaultExecFlags()
Reset the execution flags to defaults for external netlist and bom generators.
bool ReadyToNetlist(const wxString &aAnnotateMessage)
Check if we are ready to write a netlist file for the current schematic.
bool WriteNetListFile(int aFormat, const wxString &aFullFileName, unsigned aNetlistOptions, REPORTER *aReporter=nullptr)
Create a netlist file.
SCHEMATIC & Schematic() const
int m_exec_flags
Flags of the wxExecute() function to call a custom net list generator.
void sendNetlistToCvpcb()
Send the KiCad netlist over to CVPCB.
void RecalculateConnections(SCH_COMMIT *aCommit, SCH_CLEANUP_FLAGS aCleanupFlags)
Generate the connection data for the entire schematic hierarchy.
int CheckAnnotate(ANNOTATION_ERROR_HANDLER aErrorHandler, ANNOTATE_SCOPE_T aAnnotateScope=ANNOTATE_ALL, bool aRecursive=true)
Check for annotation errors.
int ModalAnnotate(const wxString &aMessage)
Run a modal version of the annotate dialog for a specific purpose.
wxString m_netListerCommand
Command line to call a custom net list generator.
A helper to define a symbol's reference designator in a schematic.
void AnnotatePowerSymbols()
Silently annotate the not yet annotated power symbols of the entire hierarchy of the sheet path list.
bool IsOK(wxWindow *aParent, const wxString &aMessage)
Display a yes/no dialog with aMessage and returns the user response.
This file is part of the common library.
#define GENERIC_INTERMEDIATE_NETLIST_EXT
KIWAY Kiway(KFCTL_STANDALONE)