substrate module#
Scaffolding shared by the JLCPCB substrates.
A buildup in this package should be a declaration of its layers and its impedance numbers and nothing else. What lives here is everything that is not those numbers.
- class JLCPCBSubstrate(*args, **kwargs)[source]#
Bases:
SubstrateBase for the substrates in this package.
A subclass declares three things: its stackup, its constraints, and the via set for its layer count and material, mixed in from vias. None of the three is fixed here on purpose. JLCPCB’s fabrication minimums differ between a 2-layer process and a multilayer one, the extra-cost via tiers apply only to 6+ layer boards, and JLCPCB fills no via on a Rogers board (mix in UnfilledVias there, not StandardVias), so a base that supplied any of them would hand substrates capabilities they cannot order.
>>> class JLC02161_Example(JLCPCBSubstrate, StandardVias): ... @inline ... class stackup(Stackup): ... layers = symmetric(...) ... constraints = JLCPCBRules()
- class Pair(trace_width, pair_spacing, clearance, uncoupled_clearance, velocity)[source]#
Bases:
objectDifferential pair geometry for one routing layer, in mm.
uncoupled_clearance applies where the pair separates and is routed as two single-ended traces; it is often tighter than the coupled clearance.
- Parameters:
- SOLDERMASK = 0.01524#
Soldermask thickness in mm, JLCPCB’s 0.6 mil above-trace figure.
- class Trace(trace_width, clearance, velocity)[source]#
Bases:
objectSingle-ended trace geometry for one routing layer, in mm.
- differential(impedance, layers, *, insertion_loss)[source]#
A differential routing structure with its uncoupled region, mirrored onto the bottom half.
- Parameters:
- Return type:
- single_ended(impedance, layers, *, insertion_loss)[source]#
A single-ended routing structure, mirrored onto the bottom half.
- symmetric(*outer, centre)[source]#
Full layer list for a buildup that mirrors about a single centre layer.
A convenience over writing the list out, not the interface: a stackup takes the full list, since several of JLCPCB’s buildups have a centre of prepreg/core/prepreg or two prepregs, and at least one published row is not symmetric at all.