Make footprint type check more narrow, and set default to ignore.
This commit is contained in:
parent
27296b5043
commit
adbbceacda
|
@ -180,12 +180,12 @@ BOARD_DESIGN_SETTINGS::BOARD_DESIGN_SETTINGS( JSON_SETTINGS* aParent, const std:
|
||||||
m_DRCSeverities[ DRCE_TEXT_HEIGHT ] = RPT_SEVERITY_WARNING;
|
m_DRCSeverities[ DRCE_TEXT_HEIGHT ] = RPT_SEVERITY_WARNING;
|
||||||
m_DRCSeverities[ DRCE_TEXT_THICKNESS ] = RPT_SEVERITY_WARNING;
|
m_DRCSeverities[ DRCE_TEXT_THICKNESS ] = RPT_SEVERITY_WARNING;
|
||||||
|
|
||||||
m_DRCSeverities[ DRCE_FOOTPRINT_TYPE_MISMATCH ] = RPT_SEVERITY_WARNING;
|
m_DRCSeverities[ DRCE_FOOTPRINT_TYPE_MISMATCH ] = RPT_SEVERITY_IGNORE;
|
||||||
|
|
||||||
m_DRCSeverities[ DRCE_LIB_FOOTPRINT_ISSUES ] = RPT_SEVERITY_WARNING;
|
m_DRCSeverities[ DRCE_LIB_FOOTPRINT_ISSUES ] = RPT_SEVERITY_WARNING;
|
||||||
m_DRCSeverities[ DRCE_LIB_FOOTPRINT_MISMATCH ] = RPT_SEVERITY_WARNING;
|
m_DRCSeverities[ DRCE_LIB_FOOTPRINT_MISMATCH ] = RPT_SEVERITY_WARNING;
|
||||||
|
|
||||||
// TODO: Change to warning after testing
|
m_DRCSeverities[ DRCE_CONNECTION_WIDTH ] = RPT_SEVERITY_WARNING;
|
||||||
m_DRCSeverities[ DRCE_CONNECTION_WIDTH ] = RPT_SEVERITY_IGNORE;
|
|
||||||
|
|
||||||
m_MaxError = ARC_HIGH_DEF;
|
m_MaxError = ARC_HIGH_DEF;
|
||||||
m_ZoneKeepExternalFillets = false;
|
m_ZoneKeepExternalFillets = false;
|
||||||
|
|
|
@ -2293,12 +2293,10 @@ std::vector<PAD*> FOOTPRINT::GetNetTiePads( PAD* aPad ) const
|
||||||
|
|
||||||
void FOOTPRINT::CheckFootprintAttributes( const std::function<void( const wxString& )>& aErrorHandler )
|
void FOOTPRINT::CheckFootprintAttributes( const std::function<void( const wxString& )>& aErrorHandler )
|
||||||
{
|
{
|
||||||
int likelyAttr = GetLikelyAttribute();
|
int likelyAttr = ( GetLikelyAttribute() & ( FP_SMD | FP_THROUGH_HOLE ) );
|
||||||
int setAttr = ( GetAttributes() & ( FP_SMD | FP_THROUGH_HOLE ) );
|
int setAttr = ( GetAttributes() & ( FP_SMD | FP_THROUGH_HOLE ) );
|
||||||
|
|
||||||
// This is only valid if the footprint doesn't have FP_SMD and FP_THROUGH_HOLE set
|
if( setAttr && likelyAttr && setAttr != likelyAttr )
|
||||||
// Which is, unfortunately, possible in theory but not in the UI (I think)
|
|
||||||
if( aErrorHandler && likelyAttr != setAttr )
|
|
||||||
{
|
{
|
||||||
wxString msg;
|
wxString msg;
|
||||||
|
|
||||||
|
@ -2310,11 +2308,9 @@ void FOOTPRINT::CheckFootprintAttributes( const std::function<void( const wxStri
|
||||||
case FP_SMD:
|
case FP_SMD:
|
||||||
msg.Printf( _( "(expected 'SMD'; actual '%s')" ), GetTypeName() );
|
msg.Printf( _( "(expected 'SMD'; actual '%s')" ), GetTypeName() );
|
||||||
break;
|
break;
|
||||||
default:
|
|
||||||
msg.Printf( _( "(expected 'Other'; actual '%s')" ), GetTypeName() );
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if( aErrorHandler )
|
||||||
(aErrorHandler)( msg );
|
(aErrorHandler)( msg );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue