build_pcb: the finisher may use In1 where the Line board has no plane (the line side)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013PRsUCpxazyipPn5UGGkF8
This commit is contained in:
Claude committed 2026-10-22 14:59:11 +00:00
1 parent 106d416457
commit 1d38702fc0
1 file changed
+5
+5
View File
@@ -981,6 +981,9 @@ def _route_link(board, net, src, dst, layers, narrow=False, rip=False, keep=()):
free[L] &= ~m
if no_v:
vfree &= ~_poly_mask(pts, X, Y, vd / 2 + 0.01)
if POUR_OUTLINE and board.GetLayerID("In1.Cu") in lid: # In1: only where its plane isn't (the line side)
L1 = board.GetLayerID("In1.Cu")
free[L1] &= ~_poly_mask(POUR_OUTLINE, X, Y, w / 2 + clr + 0.2)
for o in src + dst: # no via inside a pad of the link's own ends
if o.Type() == pcbnew.PCB_PAD_T:
vfree &= _dist(_geom(o)[0], X, Y) > vd / 2
@@ -1190,6 +1193,8 @@ def finish(board):
"""Route what's left, net by net, joining islands two at a time; if a link
won't go, rip up the nets in its way and route them again."""
layers = ["F.Cu", "In2.Cu", "B.Cu"]
if POUR_OUTLINE: # the Line board's plane covers the USB side only: In1 is free on the line side
layers.insert(1, "In1.Cu")
left = []
for net in sorted({p.GetNetname() for p in board.GetPads() if p.GetNetname()}):
if net in PLANES.values():