diff options
author | Trygve Laugstøl <trygvis@inamo.no> | 2018-07-24 18:01:39 +0200 |
---|---|---|
committer | Trygve Laugstøl <trygvis@inamo.no> | 2018-07-24 18:01:39 +0200 |
commit | 6eb5b242d0be07c0d73c3b0c0adfc33ecfa051e9 (patch) | |
tree | 42d782278a25ade1c5a53556707ec6db257166df /src | |
parent | ee520323410a7f6982f40fe9c6631c3b936bcd2d (diff) | |
download | ee-python-6eb5b242d0be07c0d73c3b0c0adfc33ecfa051e9.tar.gz ee-python-6eb5b242d0be07c0d73c3b0c0adfc33ecfa051e9.tar.bz2 ee-python-6eb5b242d0be07c0d73c3b0c0adfc33ecfa051e9.tar.xz ee-python-6eb5b242d0be07c0d73c3b0c0adfc33ecfa051e9.zip |
wip.
Diffstat (limited to 'src')
-rw-r--r-- | src/ee/ds/__init__.py | 2 | ||||
-rw-r--r-- | src/ee/kicad/doit.py | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/src/ee/ds/__init__.py b/src/ee/ds/__init__.py index c8c21dd..aff5b64 100644 --- a/src/ee/ds/__init__.py +++ b/src/ee/ds/__init__.py @@ -1,7 +1,7 @@ import configparser +import csv import logging import os -import csv from functools import total_ordering from pathlib import Path from typing import MutableMapping, Optional, List, Tuple, Union, Iterator diff --git a/src/ee/kicad/doit.py b/src/ee/kicad/doit.py index 1d0a1ed..299d3ce 100644 --- a/src/ee/kicad/doit.py +++ b/src/ee/kicad/doit.py @@ -184,6 +184,8 @@ def task_kicad_create_component_data_set(): logger.info("processing {} kicad-sch".format(len(kicad_sch))) + ignored_ref_types = set("#PRW") + for sch in kicad_sch: ref = sch.get("ref") ref_num = sch.get("ref-num") @@ -192,7 +194,7 @@ def task_kicad_create_component_data_set(): continue ref_type = sch.get("ref-type") - if not ref_type or ref_type == "#PWR": + if not ref_type or ref_type in ignored_ref_types: logger.debug("Missing ref-type or bad ref-type: ref={}, ref-type={}".format(ref, ref_type)) continue |