Sign in with STEVE

steve/pcb-relay

Through-hole PCB relays from Omron's data sheets: G2RL-2 power relay, G5V-1 and G5V-2 signal relays, G6A and G6AK signal relays.

v1.0.0 STEVE MIT 0
Isometric
part.py 63 lines · Python · STEVE runtime · checked
Download
1"""Through-hole PCB relay: Omron G2RL-2, G5V-1, G5V-2, G6A and G6AK. A closed case on the XY plane with the pins down through the board.
2Pin 1 is at the origin; the pins are placed as the maker's bottom-view PCB layout draws them, seen from above (the layout turned over
3about its horizontal axis): along it to +X, its next row towards +Y. Dimensions from the makers' data sheets in the README."""
4from steve import Model
5
6kind = "G6A" # Relay type
7
8# kind: (case length along X, width along Y, height above the board; solder pin length below the board, pin across X, pin across Y;
9# pin 1 from the case's -X end, from its -Y side; pins (x, y) from pin 1). The case sizes are the data sheets' average values.
10# Omron G2RL, Cat. No. J117-E1-17, Dimensions p. 6, G2RL-2: 29 max. (28.8 average) x 12.7 max. (12.5) x 15.7 max. (15.5), terminals 3.5 long,
11# 0.5 x 0.8; PCB mounting holes (bottom view): columns at 0, 15, 20, 25 (20 from pin 1 to the third, 5 apart), rows 7.5 apart, (2.3) from
12# the case end and (2.5) from its side. Weight approx. 12 g (p. 2).
13# Omron G5V-1, Cat. No. K048-E1-07, Dimensions p. 4: 12.5 max. (12.3) x 7.5 max. (7.3) x 10 max. (9.9), terminals 3.5 long, 0.5 x 0.3;
14# holes at 0, 2.54 and 10.16, rows 5.08 apart, (1.07) and (1.11) from the case. Weight approx. 2 g.
15# Omron G5V-2, Cat. No. K046-E1-06, Dimensions p. 4: 20.5 max. (20.3) x 10.1 max. (9.9) x 11.5 max. (11.4), terminals 3.5 long,
16# 0.5 x 0.3; holes at 0, 7.62, 12.7, 17.78, rows 7.62 apart, (1.3) and (1.2) from the case. Weight approx. 5 g.
17# Omron G6A, Cat. No. K020-E1-15, Dimensions p. 8: 20.2 max. (20) x 10.1 max. (9.9) x 8.4 max. (8.2), terminals 3.16 long, 0.6 x 0.3;
18# G6A-274P: holes at 0, 7.62, 12.7, 17.78, rows 7.62 apart, (1.2) from the case; G6AK-274P (double-winding latching): also at 2.54,
19# ten holes. Weight approx. 3.5 g (p. 2).
20RELAYS = {
21 "G2RL-2": (28.8, 12.5, 15.5, 3.5, 0.5, 0.8, 2.3, 2.5, ((0, 0), (15, 0), (20, 0), (25, 0), (0, 7.5), (15, 7.5), (20, 7.5), (25, 7.5))),
22 "G5V-1": (12.3, 7.3, 9.9, 3.5, 0.5, 0.3, 1.07, 1.11, ((0, 0), (2.54, 0), (10.16, 0), (0, 5.08), (2.54, 5.08), (10.16, 5.08))),
23 "G5V-2": (20.3, 9.9, 11.4, 3.5, 0.5, 0.3, 1.3, 1.2,
24 ((0, 0), (7.62, 0), (12.7, 0), (17.78, 0), (0, 7.62), (7.62, 7.62), (12.7, 7.62), (17.78, 7.62))),
25 "G6A": (20.0, 9.9, 8.2, 3.16, 0.6, 0.3, 1.2, 1.2,
26 ((0, 0), (7.62, 0), (12.7, 0), (17.78, 0), (0, 7.62), (7.62, 7.62), (12.7, 7.62), (17.78, 7.62))),
27 "G6AK": (20.0, 9.9, 8.2, 3.16, 0.6, 0.3, 1.2, 1.2,
28 ((0, 0), (2.54, 0), (7.62, 0), (12.7, 0), (17.78, 0), (0, 7.62), (2.54, 7.62), (7.62, 7.62), (12.7, 7.62), (17.78, 7.62))),
29}
30# Proportions (the data sheets don't dimension the inside): the case is a cover WALL thick over a base plate as thick; the coil, core and contacts inside are one
31# copper block filling FILL of the space inside the case, standing on its floor, so that the mass comes out near the data sheets' weights.
32WALL = 0.5
33FILL = 0.27
34
35if kind not in RELAYS:
36 raise ValueError(f"no relay {kind!r}: {', '.join(RELAYS)}")
37length, width, height, pin_length, pin_x, pin_y, from_end, from_side, pins = RELAYS[kind]
38# Pin 1's place in the case: the PCB layouts' bracketed distances from pin 1 to the case's end and side (the far end takes what's left
39# of the average case size).
40x0 = -from_end
41y0 = -from_side
42
43model = Model()
44# The case: a cover, open underneath, over a base plate WALL thick that closes it.
45model.box("case", length, width, height, at=(x0 + length / 2, y0 + width / 2, height / 2), op="new", body="case_body", name="Cover")
46inner = (length - 2 * WALL, width - 2 * WALL, height - 2 * WALL)
47model.box("inside", inner[0], inner[1], height - WALL, at=(x0 + length / 2, y0 + width / 2, (height - WALL) / 2), op="cut", body="case_body",
48 name="Inside")
49model.box("base", inner[0], inner[1], WALL, at=(x0 + length / 2, y0 + width / 2, WALL / 2), op="new", body="base_body", name="Base")
50scale = FILL ** (1 / 3)
51core = (inner[0] * scale, inner[1] * scale, inner[2] * scale)
52model.box("coil", core[0], core[1], core[2], at=(x0 + length / 2, y0 + width / 2, WALL + core[2] / 2), op="new", body="coil_body",
53 name="Coil and contacts")
54pin_bodies = []
55for i, (x, y) in enumerate(pins):
56 model.box(f"pin_{i + 1}", pin_x, pin_y, pin_length, at=(x, y, -pin_length / 2), op="new", body=f"pin_{i + 1}_body", name=f"Pin {i + 1}")
57 pin_bodies.append(f"pin_{i + 1}_body")
58# Materials, for looks and a rough mass (the data sheets name none): a black plastic case (pa6), the inside copper, tin-plated pins.
59model.material("pa6", bodies=["case_body", "base_body"], color="#1d1e20")
60model.material("copper", bodies=["coil_body"], color="#b87333")
61model.material("copper", bodies=pin_bodies, color="#c9cbc8")
62result = model.result()
63

Through-hole PCB relay: a closed case on the board with its pins at the maker's PCB layout. Omron G2RL-2 (DPDT power relay, 28.8 x 12.5 x 15.5), G5V-1 (SPDT, 12.3 x 7.3 x 9.9), G5V-2 (DPDT, 20.3 x 9.9 x 11.4), G6A (DPDT, 20 x 9.9 x 8.2) and G6AK (DPDT, double-winding latching, ten pins). Case sizes, pins and holes from Omron's data sheets. See the README.

PCB relay, through-hole

A through-hole PCB relay: a closed case standing on the board with its pins at the maker's PCB layout. Pin 1 is at the origin. The pins are placed as the maker's bottom-view PCB layout draws them, seen from above (the layout turned over about its horizontal axis). The layout's rows run along +X, and its next row is towards +Y. The pins go down through the board.

Type Contacts Case (average) Pins below the board Pin section PCB layout: columns from pin 1 Rows apart Pin 1 from the case end, side Weight (sheet)
G2RL-2 DPDT, power 28.8 x 12.5 x 15.5 3.5 0.5 x 0.8 0, 15, 20, 25 7.5 2.3, 2.5 approx. 12 g
G5V-1 SPDT, signal 12.3 x 7.3 x 9.9 3.5 0.5 x 0.3 0, 2.54, 10.16 5.08 1.07, 1.11 approx. 2 g
G5V-2 DPDT, signal 20.3 x 9.9 x 11.4 3.5 0.5 x 0.3 0, 7.62, 12.7, 17.78 7.62 1.3, 1.2 approx. 5 g
G6A DPDT, signal 20 x 9.9 x 8.2 3.16 0.6 x 0.3 0, 7.62, 12.7, 17.78 7.62 1.2, 1.2 approx. 3.5 g
G6AK DPDT, signal, double-winding latching 20 x 9.9 x 8.2 3.16 0.6 x 0.3 0, 2.54, 7.62, 12.7, 17.78 7.62 1.2, 1.2 approx. 3.5 g

The case sizes are the data sheets' average values (their maximums are 0.2 to 0.3 larger). The distances from pin 1 to the case are the PCB layouts' bracketed reference values, and the case's far end takes what's left of its average size.

Source

Omron data sheets, from Omron's own site (omronfs.omron.com/en_US/ecb/products/pdf/):

  • PCB Power Relay G2RL, Cat. No. J117-E1-17 (en-g2rl.pdf): weight approx. 12 g (Ratings, page 2); Dimensions, page 6, G2RL-2(-HA, -PW1), G2RL-24, G2RL-2-ASI: 29 max. (28.8) x 12.7 max. (12.5) x 15.7 max. (15.5), terminals 3.5 long, 0.5 and 0.8; PCB mounting holes: eight, 20 from pin 1 to the third column, the columns 5 apart, the rows 7.5 apart, (2.3) and (2.5) to the case.
  • Low Signal Relay G5V-1, Cat. No. K048-E1-07 (en-g5v_1.pdf): weight approx. 2 g; Dimensions, page 4: 12.5 max. (12.3) x 7.5 max. (7.3) x 10 max. (9.9), terminals 3.5, 0.5 and 0.3; six holes at 2.54, 7.62 (10.16 in all) and 5.08, (1.07) and (1.11) to the case.
  • Low Signal Relay G5V-2, Cat. No. K046-E1-06 (en-g5v_2.pdf): weight approx. 5 g; Dimensions, page 4: 20.5 max. (20.3) x 10.1 max. (9.9) x 11.5 max. (11.4), terminals 3.5, 0.5 and 0.3; eight holes at 7.62, 5.08, 5.08 and 7.62 apart, (1.3) and (1.2) to the case.
  • Low Signal Relay G6A, Cat. No. K020-E1-15 (en-g6a.pdf): weight approx. 3.5 g; Dimensions, page 8: G6A-274P and G6AU-274P, 20.2 max. (20) x 10.1 max. (9.9) x 8.4 max. (8.2), terminals 3.16 long, 0.6 and 0.3; eight holes at 7.62, 5.08, 5.08 and 7.62 apart, (1.2) to the case; G6AK-274P, ten holes, with a column 2.54 from pin 1.

The data sheets name no materials.

Proportions, for looks and mass. The data sheets don't dimension the inside. The case is a cover 0.5 thick over a base plate 0.5 thick. The coil, core and contacts inside are one copper block filling 0.27 of the space inside the case and standing on the base. That share is the same for every type.

Mass, with pa6 at 1.15 and copper at 8.96 g/cm³:

Type Model Data sheet
G2RL-2 12.4 g approx. 12 g
G5V-1 1.85 g approx. 2 g
G5V-2 4.94 g approx. 5 g
G6A, G6AK 3.45 g approx. 3.5 g

The case is black (pa6), and the pins are tin-plated copper.

The old catalogue's models

Relay_DPDT_Omron_G6A and G6AK were measured (2026-11-06): a case 20 x 9.9 x 8.2 with pins 3.16 below, pin 1 1.14 from the case's end and 1.21 from its side, against the sheet's (1.2) and (1.2). That's within 0.07, and the pins are at the same places. The catalogue's G2RL, G5V-1 and G5V-2 entries have no model. They name the part, and the sheets above give it.

The family's other relays (Finder, Schrack, Panasonic, Fujitsu, Hongfa, Kemet, COTO, Standex-Meder, SANYOU, HJR, and Omron G6H, G6K, G6S, G6E, G5LE and G5NB) aren't here yet; see COVERAGE.md.

  1. 1.4.0 Latest Compare with 1.3.0
  2. 1.3.0 Compare with 1.2.0
  3. 1.2.0 Compare with 1.1.0
  4. 1.1.0 Compare with 1.0.0
  5. 1.0.0
More #relay
STEVEMIT

steve/tht-tactile-switch

6 x 6 mm through-hole tactile switches from Omron's B3F data sheet: flat plungers 4.3 to 9.5 mm high, projected 7.3 mm, with or without a ground terminal.

0 9 sizes 0 2 hours ago v1.0.0
STEVEMIT

steve/axial-resistor

Axial leaded metal film resistor, Vishay Beyschlag MBA/SMA 0204, MBB/SMA 0207 and MBE/SMA 0414, with colour rings, horizontal or vertical.

1 9 sizes 0 7 hours ago v1.0.0
STEVEMIT

steve/bridge-rectifier

Single-phase bridge rectifiers in Vishay's through-hole cases: GBL, GBU, KBL and KBU in-line, KBPC1 and KBPC6 square, from Vishay's data sheets.

0 7 sizes 0 4 hours ago v1.0.0
STEVEMIT

steve/axial-diode

Axial leaded diodes in Vishay's DO-35, DO-41, DO-15, DO-201AD and P600 packages, with the cathode band, horizontal or vertical.

0 30 sizes 0 5 hours ago v1.0.0