eagle: Set default pin type
Eagle 7.4 DTD defines pin direction as optional with a default of IO (bidirectional). Fixes: lp:1808585 * https://bugs.launchpad.net/kicad/+bug/1808585
This commit is contained in:
parent
1e5ba6f1b1
commit
0a4812be07
|
@ -1386,6 +1386,8 @@ bool SCH_EAGLE_PLUGIN::loadSymbol( wxXmlNode* aSymbolNode, std::unique_ptr<LIB_P
|
||||||
std::unique_ptr<LIB_PIN> pin( loadPin( aPart, currentNode, &ePin, aGateNumber ) );
|
std::unique_ptr<LIB_PIN> pin( loadPin( aPart, currentNode, &ePin, aGateNumber ) );
|
||||||
pincount++;
|
pincount++;
|
||||||
|
|
||||||
|
pin->SetType( PIN_BIDI );
|
||||||
|
|
||||||
if( ePin.direction )
|
if( ePin.direction )
|
||||||
{
|
{
|
||||||
const std::map<wxString, ELECTRICAL_PINTYPE> pinDirectionsMap =
|
const std::map<wxString, ELECTRICAL_PINTYPE> pinDirectionsMap =
|
||||||
|
@ -1397,8 +1399,6 @@ bool SCH_EAGLE_PLUGIN::loadSymbol( wxXmlNode* aSymbolNode, std::unique_ptr<LIB_P
|
||||||
{ "pwr", PIN_POWER_IN },
|
{ "pwr", PIN_POWER_IN },
|
||||||
};
|
};
|
||||||
|
|
||||||
pin->SetType( PIN_UNSPECIFIED );
|
|
||||||
|
|
||||||
for( const auto& pinDir : pinDirectionsMap )
|
for( const auto& pinDir : pinDirectionsMap )
|
||||||
{
|
{
|
||||||
if( ePin.direction->Lower() == pinDir.first )
|
if( ePin.direction->Lower() == pinDir.first )
|
||||||
|
|
Loading…
Reference in New Issue