generic_bga module#

Generic hex-grid BGA component used by the design.

Physical BGA properties (rows, cols, pitch, ball diameter, signal row pairs) are canonical here, alongside the component definition itself. Signal-pair lanes start one row above the bottom edge and repeat up the row axis. Each lane uses adjacent P/N rows, and each deeper lane shifts one column over. The row gaps alternate to compensate for the hex column stagger.

ball_center(row_index, col)[source]#
Return type:

tuple[float, float]

Parameters:
signal_cols_for_pair(pair_index)[source]#
Return type:

tuple[int, ...]

Parameters:

pair_index (int)

signal_layer_for_pair(pair_index)[source]#
Return type:

int

Parameters:

pair_index (int)

class HexBGADecorated(num_rows: int, num_cols: int, ball_diameter: float, pitch: float, center_col: float | None = None)[source]#

Bases: BGADecorated

BGA with alternate-column vertical offset for hex close-packed layout.

Columns with odd index are shifted down by half the vertical pitch; column spacing is pitch * sqrt(3)/2, so nearest-neighbor ball centers sit at exactly pitch in every direction.

Parameters:
class HexBGA(*args, **kwargs)[source]#

Bases: A1, AlphaDictNumbering, HexBGADecorated

Hex-staggered BGA with A1-corner alpha/dict pad numbering.

get_pad(r, c)[source]#

Public (row, col) -> Pad lookup.

Polymorphic over the numbering mixin so design code stays decoupled from AlphaDictNumbering’s row-letter attribute layout. Wraps the framework-internal _get_pad so callers can stay clear of leading-underscore access.

Parameters:
class GenericHexGridBGA[source]#

Bases: Component

Hex-grid BGA exposing diff-pair lanes per signal row pair.

lanes[pair_index][lane_index] is the DiffPair for a given signal row pair and column slot. The flat ordering of pairs is SIGNAL_ROW_PAIRS; the column slots within a pair are signal_cols_for_pair(pair_index).

mpn: str | None = 'GENERIC_BGA_3DP'#

Manufacturer part number for this component.

manufacturer: str | None = 'Generic'#

Manufacturer for this component.

reference_designator_prefix: str | None = 'U'#

Reference designator prefix for this component. This will be used to generate a unique reference designator for each component of the same type.

Note

This field is a required data point for matching components between builds. If this value changes (including changing from unset to set), it will be treated as a new component, even if nothing else changes.

lanes: list[list[DiffPair]] = [[DiffPair(), DiffPair(), DiffPair()], [DiffPair(), DiffPair(), DiffPair()], [DiffPair(), DiffPair(), DiffPair()], [DiffPair(), DiffPair(), DiffPair()]]#
GND = [Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port(), Port()]#
landpattern = HexBGA(num_rows=21, num_cols=8, pitch=1.0, ball_diameter=0.5, center_col=3.0).pad_config(SMDPadConfig(copper=Ellipsis, soldermask=Ellipsis, paste=Ellipsis)).package_body(RectanglePackage(height=Toleranced(0.9, 0.1, 0.1), width=Toleranced(8.5, 0, 0), length=Toleranced(22.5, 0, 0)))#