ipc module#

class DensityLevel(*values)[source]#

Bases: Enum

Density Level

This enum specifies the density level for footprints on a PCB. Higher density levels indicate less space between landpatterns. These are defined in IPC-7351.

A = 'A'#

Density Level A

Maximum land protrusion

B = 'B'#

Density Level B

Median (nominal) land protrusion

C = 'C'#

Density Level C

Minimum land protrusion

class IPCRequirements(Zmax, Gmin, Xmin)[source]#

IPC Formula Results from Section 3 of IPC 7351B

This class contains the results of the IPC formula for computing the pad size.

TODO: Add Diagram here

Parameters:
Zmax: float#

Maximum overall length

Gmin: float#

Minimum distance between pads

Xmin: float#

Minimum pad width

pad_size()[source]#

Compute the pad dimensions from this IPC result

Return type:

tuple[float, float]

Returns:

The pad dimensions as (y, x)

compute_ipc(leadSpan, leadLength, leadWidth, fillets)[source]#

Compute Pad Geometry According to IPC Rules

Parameters:
  • leadSpan (Toleranced) – edge-of-lead to edge-of-lead distance for an IC package.

  • leadLength (Toleranced) – length of the exposed contact in the same dimension as leadSpan

  • leadWidth (Toleranced) – width of the exposed contact in the dimension orthogonal to leadSpan

  • fillets (LeadFillets) – Specifications for the solder fillets created when soldering the lead to the land-pattern pad. These parameters define extra spacing around the lead dimension to form these fillets.

Return type:

IPCRequirements

Returns:

IPCResult containing the results of the IPC formula

class DensityLevelContext(density_level)[source]#

Bases: Context

Parameters:

density_level (DensityLevel)

density_level: DensityLevel#
classmethod get()[source]#

Get the current active context of this type.

Return type:

DensityLevelContext

Returns:

The current context instance, or None if not set.

class DensityLevelMixin(*args, **kwargs)[source]#

Bases: Structurable

density_level(density_level)[source]#
Return type:

Self

Parameters:

density_level (DensityLevel | 'A' | 'B' | 'C')