CADSTAR PCB Archive Loader: Some fixes to design rules

1. Make sure to convert to KiCad units
2. There are some KiCad rules that have no CADSTAR equivalent.
   Make a guess as to what an appropriate rule could be.
This commit is contained in:
Roberto Fernandez Bautista 2021-02-08 10:43:02 +00:00 committed by Wayne Stambaugh
parent 2d66abdc89
commit aabe9c063f
1 changed files with 5 additions and 1 deletions

View File

@ -619,7 +619,11 @@ void CADSTAR_PCB_ARCHIVE_LOADER::loadDesignRules()
applyRule( "C_B", &ds.m_CopperEdgeClearance );
applyRule( "H_H", &ds.m_HoleToHoleMin );
ds.m_TrackMinWidth = Assignments.Technology.MinRouteWidth;
ds.m_TrackMinWidth = getKiCadLength( Assignments.Technology.MinRouteWidth );
ds.m_ViasMinSize = ds.m_TrackMinWidth; // Not specified, assumed same as track width
ds.m_ViasMinAnnulus = ds.m_TrackMinWidth / 2; // Not specified, assumed half track width
ds.m_MinThroughDrill = 0; // CADSTAR does not specify a minimum hole size
ds.m_HoleClearance = ds.m_CopperEdgeClearance; // Not specified, assumed same as edge
auto applyNetClassRule = [&]( wxString aID, ::NETCLASS* aNetClassPtr,
void ( ::NETCLASS::*aFunc )( int ) ) {