part4_routing module#

JS4 Part 4: channel B’s two byte lanes routed, on Part 3’s reference.

JS4RoutingCircuit subclasses Part 3’s JS4SIConstraintsCircuit, which is built on Part 2’s JS4PowerCircuit, which is built on Part 1’s circuit. So it holds Part 2’s decoupling, plane pours and power rules (part2_power) and Part 3’s SI constraints and spacing rules (part3_si_constraints), and its parts’ circuits are Part 2’s.

Part 4 routes every DQ, DMI and DQS of channel B’s byte lanes 0 and 1 (ch[1].d[0] and ch[1].d[1]) on CHANNEL_B_LAYER, along the paths of a reference layout (part4_reference_routes):

  • Each DQ and DMI: from its fanout via in the FPGA ball to its fanout via in the memory ball, untagged, so it keeps the 46 ohm structure inside the ball fields too (ball_field). A line with a length-matching section has a route point at each end of it, attached to the line’s memory ball; a line with none is one route from via to via.

  • Each DQS: the coupled middle section from Part 1’s FPGA pair point to its memory pair point, through two pair points of its own attached to the memory’s DQS balls, which bound its length-matching section.

Control points sit only where they are needed: at a tag transition (Part 1’s pair points, where a strobe’s ball-field segment ends) and at each end of a length-matching section. The paths’ turns guide the router between them.

The routes fix the pin assignment. The FPGA offers a byte swap within channel B and a bit swap within a byte; a route between two balls is one of those choices, and the runtime resolves the assignment to the one the routes match. Byte lane 0 leaves the FPGA from byte slot 3 and byte lane 1 from slot 2, where Part 1’s strobe escapes leave them.

Length matching is by serpentines inside length-matching sections, which the router lengthens to meet Part 3’s timing constraints:

  • A data line with a length-matching section has it where the reference layout matches that line’s length.

  • Each strobe pair has a length-matching section between its own two pair points, with a tighter serpentine pitch on the pair tag (PAIR_SERPENTINE_PITCH) so it can take more length in its room.

LINE_ENVELOPE = 0.4#

Envelope overhead, mm, of a data line’s length-matching section unless its path gives its own: the room its serpentines may take beyond its copper, half each side. A design choice: the route points that end a section grow to it, and 0.4 mm keeps those ends clear of the lines beside them at the line structure’s clearance.

PAIR_ENVELOPE = 0.3#

Envelope overhead, mm, of a strobe pair’s length-matching section. A design choice, the same way: at 0.3 mm the pair points that end each section, and the serpentines between them, leave the lines beside them room in the reference build (no Unrealizable group).

PAIR_SERPENTINE_PITCH = 0.41528999999999994#

one coupled segment of the 85 ohm differential structure on L3 (two 3.55 mil traces 6.45 mil apart) plus the substrate’s minimum copper to copper space, so adjacent turns of a pair’s serpentine sit at that minimum space. A design choice: a tighter pitch than the router’s default lets a pair take more length in the same room.

Type:

Smallest serpentine pitch, mm, on a strobe or clock pair (0.415 mm)

board_position(part, ob)[source]#

Board position of a via or pair point held by part, a child circuit of the one that declares the routes.

Return type:

Point

Parameters:
sketch(start, turns, end)[source]#

A sketch through turns, or none for a leg with no turns.

Return type:

Sketch | None

Parameters:
class JS4RoutingCircuit(params=LPDDR4ConstraintParams(skew_ck=Toleranced(0, 4e-13, 4e-13), skew_ck_cke=Toleranced(0, 4e-12, 4e-12), skew_ck_cs=Toleranced(0, 4e-12, 4e-12), skew_ck_ca=Toleranced(0, 1e-10, 1e-10), skew_ck_dqs=Toleranced(0, 1.5e-10, 1.5e-10), skew_dqs=Toleranced(0, 4e-13, 4e-13), skew_dqs_dq=Toleranced(0, 2e-11, 2e-11), spread_dq=None, loss=None), loss=1.0)[source]#

Bases: JS4SIConstraintsCircuit

Part 3’s circuit, with channel B’s two byte lanes routed.

Parameters:
route_points: list[RoutePoint]#
control_point_attachments: list[PortAttachment]#
line_routes: list[Route]#
pair_points: list[PairPoint]#
pair_routes: list[Route]#
pair(fpga_point, memory_point, memory_balls, path)[source]#

Route one strobe pair’s middle section from fpga_point to memory_point along path, through two pair points attached to memory_balls, its length-matching section between them. They face the memory with the FPGA pair point’s polarity, so each joins the leg before it at its back.

Return type:

None

Parameters:
line(fpga_ball, memory_ball, path)[source]#

Route one data line from the fanout via in fpga_ball to the one in memory_ball along path: one route, or, around a length-matching section, three, joined at route points attached to memory_ball. No route carries a tag.

Return type:

None

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

Bases: Design

Part 4’s reference: Part 3’s design, with channel B’s two byte lanes routed.

board: Board = Reference18Board()#
substrate: Substrate = Reference18Substrate()#
circuit: Circuit = JS4RoutingCircuit()#