si_geometry module#

Per-lane SI escape geometry for the BGA escape design.

Signal-via antipad shapes and keepouts, deskew-arc cross-section and per-lane knobs, GND-via stitching sites, the board-level SI cutout, and the HFSS-instrumented-lane override. Helpers here build shapes and KeepOut``s only; JITX objects with Net membership (``Pour``s, Vias) are constructed by the owning Circuit in ``bga_escape.

deskew_knobs(lane_index)[source]#

Hand-tuned (theta_exit_deg, right_r_wrap) per lane.

Smaller theta_exit_deg lengthens the P-leg wrap. right_r_wrap is the wrap radius in mm. Lane 1 carries the HFSS instrumentation.

Return type:

tuple[float, float]

Parameters:

lane_index (int)

make_si_cutout()[source]#
gnd_pad_via_sites()[source]#

GND-via stitching plan around every BGA GND ball.

Pure data: returns (row_index, col, signal_layer) triples in canonical order. BGALink constructs the actual Via instances directly (each site maps to substrate.gnd_via[signal_layer]() at the ball’s coordinates), keeping JITX object emission inside the owning Circuit rather than in a free helper.

For each signal row pair, walks the rows above and below, and at every (row, col) that isn’t itself a signal ball records the gnd_via layer that matches the row pair’s signal layer (so the via spans L1 to the signal’s lower reference plane). If two row pairs both reach the same (row, col), the deeper signal layer wins.

Return type:

list[tuple[int, int, int]]

signal_via_pair_capsule(p_pad, n_pad, radius)[source]#

Capsule with circular caps centered at the two signal via pads.

Parameters:
signal_via_pair_antipad_keepouts(keepout_shape, spec, p_pad=None, n_pad=None, split_keepout_radius=0.175, split_antipad_layers=None)[source]#

Antipad keepouts for one signal-via pair.

Always returns at least one element (the per-pair capsule cut on spec.antipad_layers); additional elements appear when split_antipad_layers (defaulting to spec.split_antipad_layers) adds per-via circular cuts on those layers.

The matching upper-reference fence Pour is not returned here: Pours must live on the same Circuit as the Net they belong to (the board-wide GND Net lives on BGALink), so BGALink constructs the Pour itself from the fence_shape exposed by each EscapeLane.

Return type:

list[KeepOut]

Parameters:
deskew_antipad_keepout_and_pour_shape(right_copper, left_copper, antipad_shape, fence_pour_shape, spec)[source]#

Build the deskew-layer keepout and the deskew fence Pour’s shape.

antipad_shape and fence_pour_shape are usually the same (the fence-pour-sized capsule unioned with buffered deskew copper). The instrumented lane decouples them: the keepout shrinks to the per-via keepout-sized capsule so the L4 cut stays small even when the L1 D-cut envelope grows.

The Pour itself is constructed by BGALink (it must live on the same Circuit as the GND Net it belongs to), so we return the keepout (no Net membership, lives on EscapeLane) and the shape the Pour needs.

Return type:

tuple[KeepOut, ShapelyGeometry]

Parameters:

spec (PerSignalLayerSpec)

instrumented_l1_d_keepouts(p_pad, n_pad)[source]#
Return type:

list[KeepOut]

Parameters:
is_instrumented_lane(pair_index, lane_index)[source]#

The HFSS-instrumented lane lives on a specific Signal2 row pair.

The signal-layer guard is defensive: if _INSTRUMENTED_ROW_PAIR is ever retargeted off Signal2, the Signal2-specific override (L1 D-cuts + enlarged L2/L3 circles) silently no-ops instead of misapplying to a different layer’s antipad stack.

Return type:

bool

Parameters:
  • pair_index (int)

  • lane_index (int)