jitx.sample package#
The sample package contains sample classes of common base design elements, primarily useful for creating test cases, and can be used when experimenting without wanting to select a stackup or fabrication rules. The implementations in here do not reflect any real world applications, and may be changed at any time without notice, and thus should not be relied upon when creating actual designs.
>>> class MyPlayground(SampleDesign):
... @inline
... class circuit(Circuit):
... silly_port = Port()
... ...
- class SoldermaskLayer(*, name=None, thickness=None)[source]#
Bases:
Dielectric
- class Core(*, name=None, thickness=None)[source]#
Bases:
Dielectric
- class Prepreg(*, name=None, thickness=None)[source]#
Bases:
Dielectric
- class SampleStackup(layer_count)[source]#
Bases:
Stackup- Parameters:
layer_count (int)
- top_surface = <jitx.sample.SoldermaskLayer object>#
- bottom_surface = <jitx.sample.SoldermaskLayer object>#
- class SampleTwoLayerStackup[source]#
Bases:
SampleStackup
- class SampleFabConstraints[source]#
Bases:
FabricationConstraints-
min_copper_width:
float= 0.127# Minimum permissible copper width. This constraint will be enforced by the engine for generated copper shapes and will take precedence over other constraints and rules, such as trace width.
-
min_copper_copper_space:
float= 0.127# Minimum permissible copper-to-copper spacing. This constraint will be enforced by the engine for generated copper shapes and will take precedence over other constraints and rules, such as clearance.
-
min_copper_hole_space:
float= 0.2032# Minimum permissible copper-to-hole spacing. This constraint will be enforced by the engine for generated copper shapes and will take precedence over other constraints and rules, such as clearance.
-
min_copper_edge_space:
float= 0.5# Minimum permissible copper-to-board-edge spacing. This constraint will be enforced by the engine for generated copper shapes and will take precedence over other constraints and rules, such as clearance.
-
min_silk_solder_mask_space:
float= 0.15# Minimum distance between silkscreen and soldermask features.
-
solder_mask_registration:
float= 0.15# Minimum distance between soldermask and the edge of a copper pad.
-
min_copper_width:
- class SampleSubstrate(*args, **kwargs)[source]#
Bases:
SubstrateSample substrate using a two layer stackup and the sample fabrication constraints.
- stackup: Stackup = <jitx.sample.SampleTwoLayerStackup object>#
- constraints: FabricationConstraints = <jitx.sample.SampleFabConstraints object>#
- class MicroVia[source]#
Bases:
Via- start_layer: ClassVar[int] = 0#
Starting layer for the via. Setting this to a layer index other than the top layer allows for creating buried or blind vias.
- stop_layer: ClassVar[int] = 1#
Ending layer for the via.
- diameter: ClassVar[float | ViaDiameter] = 0.3#
Pad diameter of the via, in mm. Can be overridden on a per-layer basis by
diameters.
- hole_diameter: ClassVar[float] = 0.1#
Drilled or laser-cut hole diameter for the via, in mm.
- filled: ClassVar[bool] = True#
Whether the via is filled.
- tented: ClassVar[set[Side] | Side | None | bool] = 0#
Whether the via is tented on Top, Bottom, or both sides. Untented sides will have a solder mask opening.
- type: ClassVar[ViaType] = 2#
MechanicalDrill or LaserDrill.
- Type:
Type of via drilling method
- class THVia[source]#
Bases:
Via- start_layer: ClassVar[int] = 0#
Starting layer for the via. Setting this to a layer index other than the top layer allows for creating buried or blind vias.
- stop_layer: ClassVar[int] = -1#
Ending layer for the via.
- diameter: ClassVar[float | ViaDiameter] = 0.45#
Pad diameter of the via, in mm. Can be overridden on a per-layer basis by
diameters.
- hole_diameter: ClassVar[float] = 0.3#
Drilled or laser-cut hole diameter for the via, in mm.
- type: ClassVar[ViaType] = 1#
MechanicalDrill or LaserDrill.
- Type:
Type of via drilling method
- RS_50 = RoutingStructure(impedance=50 Ω)#
- DRS_100 = DifferentialRoutingStructure(name=100 Ohm Differential Routing Structure, impedance=100 Ω)#
- class SampleLogo(transform)[source]#
Bases:
Composite- Parameters:
transform (T | None)
- logo = [Silkscreen(shape=ArcPolygon(elements=[(129.99511, 106.11806), (155.77751, 252.92654), (155.77751, 252.92654), (127.07961, 252.92794), (127.07961, 252.92794), (100.88372, 104.07677), Arc(center=(50.63525, 118.77768), radius=52.3547937251375, start=343.692212564259, arc=-73.036), (51.23486, 66.42632), (46.48195, 37.846), Arc(center=(39.72792, 131.34997), radius=93.74758, start=274.131472313522, arc=70.1282911141564)]), side=<Side.Top: 0>), Silkscreen(shape=ArcPolygon(elements=[(161.37197, 109.53154), (186.14702, 109.58264), Arc(center=(187.78956, 120.45189), radius=10.9926581505157, start=261.406594070027, arc=-90.0), (176.92031, 122.09443), (197.30991, 239.93381), Arc(center=(185.69481, 241.28834), radius=11.69381, start=353.348467089116, arc=90.0), (187.04931, 252.90344), (161.24171, 252.88594), Arc(center=(159.87001, 241.55414), radius=11.3999014754514, start=82.2379279356338, arc=-89.0), (171.19061, 240.21184), (150.64721, 120.99825), Arc(center=(161.74291, 120.62724), radius=11.1019, start=178.084937086803, arc=90.0000126632972)]), side=<Side.Top: 0>), Silkscreen(shape=ArcPolygon(elements=[Arc(center=(192.79512, 280.0784), radius=18.48297, start=90.045434172056, arc=66.0875592258654), Arc(center=(187.62571, 281.66284), radius=13.13026, start=153.32723335444, arc=90.0000049753901), Arc(center=(187.00212, 285.99534), radius=16.90794, start=251.837227244361, arc=80.7081864800818), Arc(center=(191.6858, 286.02582), radius=12.95168, start=322.826473363368, arc=90.0), Arc(center=(191.49081, 283.31024), radius=15.30556, start=58.3960486943029, arc=26.7704478088988)]), side=<Side.Top: 0>), Silkscreen(shape=Polygon(elements=[(192.21811, 109.47134), (220.88521, 109.47204), (220.88521, 109.47204), (243.89771, 240.25584), (243.89771, 240.25584), (281.90071, 240.31184), (281.90071, 240.31184), (287.04781, 269.85464), (287.04781, 269.85464), (249.13091, 269.87074), (249.13091, 269.87074), (254.13451, 298.55814), (254.13451, 298.55814), (225.48071, 298.55604), (225.48071, 298.55604), (192.21811, 109.47134)], holes=()), side=<Side.Top: 0>), Silkscreen(shape=ArcPolygon(elements=[(320.43221, 124.54584), (352.25071, 166.56614), (352.25071, 166.56614), (385.77918, 212.30018), (385.77918, 212.30018), (368.54126, 256.67461), (368.54126, 256.67461), (347.41301, 311.06364), (347.41301, 311.06364), (294.69251, 311.11124), (294.69251, 311.11124), (332.55271, 210.13204), (332.55271, 210.13204), (267.96461, 124.89584), Arc(center=(231.32182, 159.73793), radius=50.5634830915771, start=316.442884579526, arc=-40.158), (236.85711, 109.47834), (288.27911, 109.48569), Arc(center=(288.35845, 151.16948), radius=41.68387, start=269.890956168332, arc=50.4138162580514)]), side=<Side.Top: 0>), Silkscreen(shape=Polygon(elements=[(352.25071, 166.56614), (385.77918, 212.30018), (425.72271, 109.47624), (376.16831, 109.46994), (352.25071, 166.56614)], holes=()), side=<Side.Top: 0>), Silkscreen(shape=ArcPolygon(elements=[(385.77918, 212.30018), (448.17761, 296.47284), Arc(center=(480.32967, 268.80635), radius=42.4168484792977, start=139.294560100257, arc=-49.948), (480.81341, 311.22044), (430.08697, 311.1661), Arc(center=(427.43546, 269.54979), radius=41.70069, start=86.354432664842, arc=47.8643206763705), (368.54126, 256.67461), (398.35341, 299.43594), (368.54126, 256.67461), (385.77918, 212.30018)]), side=<Side.Top: 0>)]#
- class SampleBoard[source]#
Bases:
Board50 x 50mm rectangle board with rounded corners.
- shape: Shape = ArcPolygon(elements=(Arc(center=(20.0, 20.0), radius=5, start=0.0, arc=90.0), Arc(center=(-20.0, 20.0), radius=5, start=90.0, arc=90.0), Arc(center=(-20.0, -20.0), radius=5, start=180.0, arc=90.0), Arc(center=(20.0, -20.0), radius=5, start=270.0, arc=90.0)))#
The board outline shape.
- logo = SampleLogo(Transform((14, -24), 0, (0.02, 0.02)))#