Respect exclude from bom in all python files
Two scripts were missing the excludeBOM=True selector.
This commit is contained in:
parent
169ece3b71
commit
a1f796ffa0
|
@ -52,10 +52,13 @@ out.writerow( ['Generator:', sys.argv[0]] )
|
||||||
out.writerow(['Component Count:', len(net.components)])
|
out.writerow(['Component Count:', len(net.components)])
|
||||||
out.writerow(['Ref', 'Qnty', 'Value', 'Cmp name', 'Footprint', 'Description', 'Vendor', 'DNP'])
|
out.writerow(['Ref', 'Qnty', 'Value', 'Cmp name', 'Footprint', 'Description', 'Vendor', 'DNP'])
|
||||||
|
|
||||||
|
# subset the components to those wanted in the BOM, controlled
|
||||||
|
# by <configure> block in kicad_netlist_reader.py
|
||||||
|
components = net.getInterestingComponents( excludeBOM=True )
|
||||||
|
|
||||||
# Get all of the components in groups of matching parts + values
|
# Get all of the components in groups of matching parts + values
|
||||||
# (see ky_generic_netlist_reader.py)
|
# (see ky_generic_netlist_reader.py)
|
||||||
grouped = net.groupComponents()
|
grouped = net.groupComponents(components)
|
||||||
|
|
||||||
# Output all of the component information
|
# Output all of the component information
|
||||||
for group in grouped:
|
for group in grouped:
|
||||||
|
@ -67,9 +70,9 @@ for group in grouped:
|
||||||
for component in group:
|
for component in group:
|
||||||
refs_l.append( fromNetlistText( component.getRef() ) )
|
refs_l.append( fromNetlistText( component.getRef() ) )
|
||||||
c = component
|
c = component
|
||||||
|
|
||||||
refs = ", ".join(refs_l)
|
refs = ", ".join(refs_l)
|
||||||
|
|
||||||
# Fill in the component groups common data
|
# Fill in the component groups common data
|
||||||
out.writerow([refs, len(group),
|
out.writerow([refs, len(group),
|
||||||
fromNetlistText( c.getValue() ),
|
fromNetlistText( c.getValue() ),
|
||||||
|
|
|
@ -86,9 +86,11 @@ out = csv.writer(f, lineterminator='\n', delimiter=',', quotechar='\"', quoting=
|
||||||
# Output a CSV header
|
# Output a CSV header
|
||||||
out.writerow(header_names)
|
out.writerow(header_names)
|
||||||
|
|
||||||
|
components = net.getInterestingComponents( excludeBOM=True )
|
||||||
|
|
||||||
# Get all of the components in groups of matching parts + values
|
# Get all of the components in groups of matching parts + values
|
||||||
# (see kicad_netlist_reader.py)
|
# (see kicad_netlist_reader.py)
|
||||||
grouped = net.groupComponents()
|
grouped = net.groupComponents(components)
|
||||||
|
|
||||||
# Output all of the component information
|
# Output all of the component information
|
||||||
index = 1
|
index = 1
|
||||||
|
@ -101,9 +103,9 @@ for group in grouped:
|
||||||
for component in group:
|
for component in group:
|
||||||
refs_l.append( component.getRef() )
|
refs_l.append( component.getRef() )
|
||||||
c = component
|
c = component
|
||||||
|
|
||||||
refs = ", ".join(refs_l)
|
refs = ", ".join(refs_l)
|
||||||
|
|
||||||
# Fill in the component groups common data
|
# Fill in the component groups common data
|
||||||
row = []
|
row = []
|
||||||
row.append( index )
|
row.append( index )
|
||||||
|
|
Loading…
Reference in New Issue