@@ -126,7 +126,7 @@ def startPanelizer(self, args, board=None, ordering=None, logger=None):
126
126
127
127
# 'Extra' ordering instructions
128
128
# Any PCB_TEXT containing any of these keywords will be copied into the ordering instructions
129
- possibleExtras = ['clean' , 'Clean' , 'CLEAN' ]
129
+ possibleExtras = ['clean' , 'Clean' , 'CLEAN' , 'stackup' , 'Stackup' , 'STACKUP' ]
130
130
131
131
# Permutations for Ordering Instructions
132
132
possibleOrderingInstructions = [
@@ -428,7 +428,7 @@ def startPanelizer(self, args, board=None, ordering=None, logger=None):
428
428
sparkxLogoSeen = False
429
429
solderMask = None
430
430
silkscreen = None
431
- numLayers = "Layers: {}" .format (board .GetCopperLayerCount ())
431
+ copperLayers = "Layers: {}" .format (board .GetCopperLayerCount ()) # Should we trust the instructions or the tracks?!
432
432
controlledImpedance = None
433
433
finish = None
434
434
thickness = None
@@ -568,8 +568,8 @@ def startPanelizer(self, args, board=None, ordering=None, logger=None):
568
568
if "mask" in line or "Mask" in line or "MASK" in line :
569
569
solderMask = line
570
570
if "layers" in line or "Layers" in line or "LAYERS" in line :
571
- if numLayers is None : # Should we trust the instructions or the tracks?!
572
- numLayers = line
571
+ if copperLayers is None : # Should we trust the instructions or the tracks?!
572
+ copperLayers = line
573
573
if "impedance" in line or "Impedance" in line or "IMPEDANCE" in line :
574
574
controlledImpedance = line
575
575
if "finish" in line or "Finish" in line or "FINISH" in line :
@@ -579,7 +579,10 @@ def startPanelizer(self, args, board=None, ordering=None, logger=None):
579
579
if "material" in line or "Material" in line or "MATERIAL" in line :
580
580
material = line
581
581
if "weight" in line or "Weight" in line or "WEIGHT" in line or "oz" in line or "Oz" in line or "OZ" in line :
582
- copperWeight = line
582
+ if copperWeight is None :
583
+ copperWeight = line
584
+ else :
585
+ copperWeight += "\n " + line
583
586
for extra in possibleExtras :
584
587
if extra in line :
585
588
if orderingExtras is None :
@@ -1188,9 +1191,9 @@ def startPanelizer(self, args, board=None, ordering=None, logger=None):
1188
1191
if silkscreen is None :
1189
1192
silkscreen = "Silkscreen: White (Default)"
1190
1193
report += silkscreen + "\n "
1191
- if numLayers is None :
1192
- numLayers = "Layers: 2 (Default)"
1193
- report += numLayers + "\n "
1194
+ if copperLayers is None :
1195
+ copperLayers = "Layers: 2 (Default)"
1196
+ report += copperLayers + "\n "
1194
1197
if finish is None :
1195
1198
finish = "Finish: HASL Lead-free (Default)"
1196
1199
report += finish + "\n "
@@ -1233,12 +1236,12 @@ def startPanelizer(self, args, board=None, ordering=None, logger=None):
1233
1236
'Warning' , wx .OK | wx .ICON_WARNING )
1234
1237
silkscreen = "Silkscreen: White (Default)"
1235
1238
oi .write (silkscreen + "\n " )
1236
- if numLayers is None :
1239
+ if copperLayers is None :
1237
1240
if wx .GetApp () is not None and orderingInstructionsSeen :
1238
1241
resp = wx .MessageBox ("Number of layers not found!" ,
1239
1242
'Warning' , wx .OK | wx .ICON_WARNING )
1240
- numLayers = "Layers: 2 (Default)"
1241
- oi .write (numLayers + "\n " )
1243
+ copperLayers = "Layers: 2 (Default)"
1244
+ oi .write (copperLayers + "\n " )
1242
1245
if finish is None :
1243
1246
if wx .GetApp () is not None and orderingInstructionsSeen :
1244
1247
resp = wx .MessageBox ("PCB finish not found!" ,
0 commit comments