|
KiCad PCB EDA Suite
|
Go to the source code of this file.
Classes | |
| struct | NET_RECONCILE_RESULT |
| Outcome of naming the nets of an imported board after the nets of its schematic. More... | |
Functions | |
| int | ReconcileImportedReferences (BOARD &aBoard, NETLIST &aNetlist) |
| Give an imported board footprint the reference its schematic symbol uses. | |
| NET_RECONCILE_RESULT | ReconcileImportedNetNames (BOARD &aBoard, NETLIST &aNetlist, REPORTER &aReporter) |
| Give each net of an imported board the name its schematic uses. | |
| int | FillImportedFootprintFields (BOARD &aBoard, NETLIST &aNetlist) |
| Copy what an imported board footprint lacks from the schematic symbol it is linked to. | |
Copy what an imported board footprint lacks from the schematic symbol it is linked to.
A footprint takes the symbol's value only when its own is empty and gains only the symbol fields it does not have, the same set Update PCB from Schematic copies. Nothing the board already holds changes.
| [in] | aBoard | is the imported board whose footprints are completed. |
| [in] | aNetlist | is the netlist of the imported schematic. |
Definition at line 267 of file import_net_reconciler.cpp.
References FOOTPRINT::Add(), B_Fab, F_Cu, F_Fab, FOOTPRINT, NETLIST::GetComponent(), NETLIST::GetCount(), GetDefaultFieldName(), BOARD::GetDesignSettings(), FOOTPRINT::GetField(), COMPONENT::GetFields(), FOOTPRINT::GetLayer(), FOOTPRINT::GetOrientation(), FOOTPRINT::GetPosition(), COMPONENT::GetReference(), COMPONENT::GetValue(), FOOTPRINT::GetValue(), FOOTPRINT::HasField(), name, REFERENCE, PCB_TEXT::Rotate(), BOARD_ITEM::SetLayer(), PCB_FIELD::SetName(), PCB_TEXT::SetPosition(), EDA_TEXT::SetText(), FOOTPRINT::SetValue(), EDA_TEXT::SetVisible(), PCB_TEXT::StyleFromSettings(), UNTRANSLATED, USER, and VALUE.
Referenced by BOOST_AUTO_TEST_CASE(), and PCB_EDIT_FRAME::KiwayMailIn().
| NET_RECONCILE_RESULT ReconcileImportedNetNames | ( | BOARD & | aBoard, |
| NETLIST & | aNetlist, | ||
| REPORTER & | aReporter ) |
Give each net of an imported board the name its schematic uses.
A board net is renamed only when its pads, on the footprints both documents share, are exactly the pins of one schematic net. A net the two documents divide differently keeps its name and is reported, so a real difference between them stays visible. A pad that has no net but whose schematic net joins nothing else takes that net's name.
Shared by the project manager's import and the kicad-cli import job.
| [in] | aBoard | is the imported board whose nets are renamed. |
| [in] | aNetlist | is the netlist of the imported schematic. |
| [in] | aReporter | receives the counts and the first differences. |
Definition at line 136 of file import_net_reconciler.cpp.
References _, BOARD::Add(), ApplyImportedNetNameMap(), BOARD::FindNet(), NETLIST::GetComponent(), NETLIST::GetCount(), COMPONENT::GetNet(), COMPONENT::GetNetCount(), COMPONENT::GetReference(), name, pad, pin, REPORTER::Report(), result, and RPT_SEVERITY_INFO.
Referenced by PCB_EDIT_FRAME::KiwayMailIn().
Give an imported board footprint the reference its schematic symbol uses.
Only a footprint whose reference no symbol has is renamed, and only when exactly one unmatched symbol reference equals it ignoring case or once the importer's "UNK" prefix is removed. Run this before the net names are reconciled, since both match footprints by reference.
| [in] | aBoard | is the imported board whose footprints are renamed. |
| [in] | aNetlist | is the netlist of the imported schematic. |
Definition at line 68 of file import_net_reconciler.cpp.
References BOARD::Footprints(), NETLIST::GetComponent(), NETLIST::GetCount(), and COMPONENT::GetReference().
Referenced by BOOST_AUTO_TEST_CASE(), and PCB_EDIT_FRAME::KiwayMailIn().