@rulecad/rules 0.3.17 → 0.3.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,17 @@
3
3
  What changed in each release, for someone upgrading a workspace. A rule set's **values** are the figures designs
4
4
  read (`m3.clearance`, `x1c.hole_comp`). Each release says whether any value changed, and why.
5
5
 
6
+ ## 0.3.18: Kailh Choc v1, DO-35 diodes
7
+
8
+ ### Added
9
+
10
+ - `do35`: DO-35 axial diodes (the 1N4148): lead pitch, pads and drill from KiCad's footprint, body and lead sizes.
11
+ - `choc`: the Kailh Choc v1 (PG1350) PCB footprint (pins, centre post, pegs) from ergogen's widely used footprint,
12
+ its housing and height from Kailh's drawing, and MX key spacing for boards that take both.
13
+
14
+ ### Values that changed
15
+
16
+ None.
6
17
  ## 0.3.17: printed beams (Frames 3)
7
18
 
8
19
  ### Added
package/README.md CHANGED
@@ -13,9 +13,11 @@ it comes from and when it was checked, so a design built on it can be traced and
13
13
  | `wire` | Hook-up wire by gauge: current density, service loop | 4 |
14
14
  | `x1c` | Bambu Lab X1 Carbon: bed, line width, layer, overhang, bridges, fits, the gap parts printed in place need (and how far the first layer spreads), hole compensation, the gap a printed screw thread leaves its mate (`thread_gap`, an estimate), and the measured pilot for an M3 screw in PLA (`pilot_m3`) | 14 |
15
15
  | `mx` | Cherry MX switches: plate cut-out, stem, housing, travel, key pitch | 29 |
16
+ | `choc` | Kailh Choc v1 (PG1350) switches: the PCB footprint (pins, centre post, pegs), housing, height | 13 |
16
17
  | `oem` | OEM keycap profile: heights and top tilt per row (from KeyV2) | 12 |
17
18
  | `pico` | Raspberry Pi Pico: outline, headers, the GPIO on each pin | 18 |
18
19
  | `promicro` | Pro Micro controller | 9 |
20
+ | `do35` | DO-35 axial diodes (1N4148): lead pitch, pads and drill, body size, for through-hole keyboard matrices | 7 |
19
21
  | `sod123` | SOD-123 diode footprint | 3 |
20
22
  | `xiao` | Seeed Studio XIAO modules: outline, headers, the pin on each pad | 8 |
21
23
  | `qwiic` | Qwiic / STEMMA QT sockets (JST SH, 4 pins): land pattern and pinout | 10 |
package/choc.json ADDED
@@ -0,0 +1,110 @@
1
+ {
2
+ "_doc": "Kailh Choc v1 (PG1350) low-profile switches: the PCB footprint. Positions from the switch's centre, seen from above, y up (behind the switch is +y). kind as in x1c.json.",
3
+ "name": "choc",
4
+ "rules": {
5
+ "pitch": {
6
+ "value": 19.05,
7
+ "unit": "mm",
8
+ "rule": "Key spacing on a board that also takes MX switches (Choc's own is 18 x 17 mm)",
9
+ "kind": "spec",
10
+ "source": "Cherry MX keyboard layout convention: a hybrid MX/Choc board keeps MX spacing",
11
+ "checked": "2026-11-20"
12
+ },
13
+ "pcb_pin1_x": {
14
+ "value": 0,
15
+ "unit": "mm",
16
+ "rule": "PCB footprint: pin 1, on the centre line",
17
+ "kind": "community",
18
+ "source": "ergogen's Kailh Choc v1 footprint, https://github.com/ergogen/ergogen/blob/master/src/footprints/choc.js (KiCad frame, y down; turned to y up here), MIT",
19
+ "checked": "2026-11-20"
20
+ },
21
+ "pcb_pin1_y": {
22
+ "value": 5.9,
23
+ "unit": "mm",
24
+ "rule": "PCB footprint: pin 1, behind the centre",
25
+ "kind": "community",
26
+ "source": "ergogen's Kailh Choc v1 footprint, https://github.com/ergogen/ergogen/blob/master/src/footprints/choc.js (KiCad frame, y down; turned to y up here), MIT",
27
+ "checked": "2026-11-20"
28
+ },
29
+ "pcb_pin2_x": {
30
+ "value": 5,
31
+ "unit": "mm",
32
+ "rule": "PCB footprint: pin 2, right of the centre",
33
+ "kind": "community",
34
+ "source": "ergogen's Kailh Choc v1 footprint, https://github.com/ergogen/ergogen/blob/master/src/footprints/choc.js (KiCad frame, y down; turned to y up here), MIT",
35
+ "checked": "2026-11-20"
36
+ },
37
+ "pcb_pin2_y": {
38
+ "value": 3.8,
39
+ "unit": "mm",
40
+ "rule": "PCB footprint: pin 2, behind the centre",
41
+ "kind": "community",
42
+ "source": "ergogen's Kailh Choc v1 footprint, https://github.com/ergogen/ergogen/blob/master/src/footprints/choc.js (KiCad frame, y down; turned to y up here), MIT",
43
+ "checked": "2026-11-20"
44
+ },
45
+ "pcb_pin_drill": {
46
+ "value": 1.27,
47
+ "unit": "mm",
48
+ "rule": "PCB footprint: drill for the two electrical pins",
49
+ "kind": "community",
50
+ "source": "ergogen's Kailh Choc v1 footprint, https://github.com/ergogen/ergogen/blob/master/src/footprints/choc.js (KiCad frame, y down; turned to y up here), MIT",
51
+ "checked": "2026-11-20"
52
+ },
53
+ "pcb_pin_pad": {
54
+ "value": 2.032,
55
+ "unit": "mm",
56
+ "rule": "PCB footprint: copper pad round each electrical pin",
57
+ "kind": "community",
58
+ "source": "ergogen's Kailh Choc v1 footprint, https://github.com/ergogen/ergogen/blob/master/src/footprints/choc.js (KiCad frame, y down; turned to y up here), MIT",
59
+ "checked": "2026-11-20"
60
+ },
61
+ "pcb_centre_hole": {
62
+ "value": 3.429,
63
+ "unit": "mm",
64
+ "rule": "PCB footprint: unplated hole for the switch's centre post",
65
+ "kind": "community",
66
+ "source": "ergogen's Kailh Choc v1 footprint, https://github.com/ergogen/ergogen/blob/master/src/footprints/choc.js (KiCad frame, y down; turned to y up here), MIT",
67
+ "checked": "2026-11-20"
68
+ },
69
+ "pcb_peg_x": {
70
+ "value": 5.5,
71
+ "unit": "mm",
72
+ "rule": "PCB footprint: the two locating pegs, either side of the centre",
73
+ "kind": "community",
74
+ "source": "ergogen's Kailh Choc v1 footprint, https://github.com/ergogen/ergogen/blob/master/src/footprints/choc.js (KiCad frame, y down; turned to y up here), MIT",
75
+ "checked": "2026-11-20"
76
+ },
77
+ "pcb_peg_hole": {
78
+ "value": 1.7018,
79
+ "unit": "mm",
80
+ "rule": "PCB footprint: unplated holes for the locating pegs",
81
+ "kind": "community",
82
+ "source": "ergogen's Kailh Choc v1 footprint, https://github.com/ergogen/ergogen/blob/master/src/footprints/choc.js (KiCad frame, y down; turned to y up here), MIT",
83
+ "checked": "2026-11-20"
84
+ },
85
+ "pcb_body": {
86
+ "value": 15,
87
+ "unit": "mm",
88
+ "rule": "The switch's housing seen from above: 15 x 15 mm, nothing taller than a pad under it",
89
+ "kind": "spec",
90
+ "source": "Kailh PG1350 drawing, as quoted at https://deskthority.net/wiki/Kailh_PG1350_series (15 x 15 x 8 mm)",
91
+ "checked": "2026-11-20"
92
+ },
93
+ "height_pcb": {
94
+ "value": 8,
95
+ "unit": "mm",
96
+ "rule": "Switch height above the PCB, without a keycap (with a 1.2 mm plate the housing sits on the plate)",
97
+ "kind": "spec",
98
+ "source": "Kailh PG1350 drawing, as quoted at https://deskthority.net/wiki/Kailh_PG1350_series",
99
+ "checked": "2026-11-20"
100
+ },
101
+ "pin_length": {
102
+ "value": 3,
103
+ "unit": "mm",
104
+ "rule": "Electrical pins below the housing (they reach through a 1.6 mm board by about 1.4 mm before trimming)",
105
+ "kind": "estimate",
106
+ "source": "Kailh PG1350 drawing (3.0 mm pins): measure a switch to confirm",
107
+ "checked": "2026-11-20"
108
+ }
109
+ }
110
+ }
package/do35.json ADDED
@@ -0,0 +1,62 @@
1
+ {
2
+ "_doc": "DO-35 axial diodes (the 1N4148, a keyboard's matrix diode, through-hole), lying flat on the board with their leads bent down at 0.3 in. kind as in x1c.json.",
3
+ "name": "do35",
4
+ "rules": {
5
+ "pitch": {
6
+ "value": 7.62,
7
+ "unit": "mm",
8
+ "rule": "Lead holes this far apart: the leads bent down at 0.3 in",
9
+ "kind": "community",
10
+ "source": "KiCad footprint library, Diode_THT.pretty/D_DO-35_SOD27_P7.62mm_Horizontal.kicad_mod (from Diodes Inc.'s DO-35 drawing, http://www.diodes.com/_files/packages/DO-35.pdf), https://gitlab.com/kicad/libraries/kicad-footprints",
11
+ "checked": "2026-11-20"
12
+ },
13
+ "drill": {
14
+ "value": 0.8,
15
+ "unit": "mm",
16
+ "rule": "Lead hole drill (a 0.5 mm lead)",
17
+ "kind": "community",
18
+ "source": "KiCad footprint library, Diode_THT.pretty/D_DO-35_SOD27_P7.62mm_Horizontal.kicad_mod (from Diodes Inc.'s DO-35 drawing, http://www.diodes.com/_files/packages/DO-35.pdf), https://gitlab.com/kicad/libraries/kicad-footprints",
19
+ "checked": "2026-11-20"
20
+ },
21
+ "pad": {
22
+ "value": 1.6,
23
+ "unit": "mm",
24
+ "rule": "Round copper pad round each lead",
25
+ "kind": "community",
26
+ "source": "KiCad footprint library, Diode_THT.pretty/D_DO-35_SOD27_P7.62mm_Horizontal.kicad_mod (from Diodes Inc.'s DO-35 drawing, http://www.diodes.com/_files/packages/DO-35.pdf), https://gitlab.com/kicad/libraries/kicad-footprints",
27
+ "checked": "2026-11-20"
28
+ },
29
+ "body_length": {
30
+ "value": 4,
31
+ "unit": "mm",
32
+ "rule": "The glass body's length",
33
+ "kind": "community",
34
+ "source": "KiCad footprint library, Diode_THT.pretty/D_DO-35_SOD27_P7.62mm_Horizontal.kicad_mod (from Diodes Inc.'s DO-35 drawing, http://www.diodes.com/_files/packages/DO-35.pdf), https://gitlab.com/kicad/libraries/kicad-footprints",
35
+ "checked": "2026-11-20"
36
+ },
37
+ "body_d": {
38
+ "value": 2,
39
+ "unit": "mm",
40
+ "rule": "The glass body's diameter",
41
+ "kind": "community",
42
+ "source": "KiCad footprint library, Diode_THT.pretty/D_DO-35_SOD27_P7.62mm_Horizontal.kicad_mod (from Diodes Inc.'s DO-35 drawing, http://www.diodes.com/_files/packages/DO-35.pdf), https://gitlab.com/kicad/libraries/kicad-footprints",
43
+ "checked": "2026-11-20"
44
+ },
45
+ "lead_d": {
46
+ "value": 0.5,
47
+ "unit": "mm",
48
+ "rule": "Lead wire diameter",
49
+ "kind": "spec",
50
+ "source": "Vishay 1N4148 datasheet, DO-35 package drawing (0.45 to 0.55 mm leads), https://www.vishay.com/docs/81857/1n4148.pdf",
51
+ "checked": "2026-11-20"
52
+ },
53
+ "lead_out": {
54
+ "value": 1.5,
55
+ "unit": "mm",
56
+ "rule": "Leads left below the board once trimmed",
57
+ "kind": "estimate",
58
+ "source": "Common practice: trim leads to about 1.5 mm after soldering",
59
+ "checked": "2026-11-20"
60
+ }
61
+ }
62
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rulecad/rules",
3
- "version": "0.3.17",
3
+ "version": "0.3.18",
4
4
  "description": "Researched rule sets as open data: a Bambu Lab X1C, Cherry MX switches, OEM keycaps, M2 inserts, the Raspberry Pi Pico, motors and servos, materials for analysis (printed PLA and PETG, aluminium, steel, titanium) and more, each value with its source.",
5
5
  "type": "module",
6
6
  "exports": {