create-rulecad 0.3.16 → 0.3.17

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
@@ -5,6 +5,13 @@ print (a hole's diameter, a seat's depth, a part's outline). Each release lists
5
5
  it makes, with its reason. A **fasten** is an entry in an assembly's `"fasten"` list: one screwed joint, naming the
6
6
  screw by thread and head, the parts it passes through and the part it ends in.
7
7
 
8
+ ## 0.3.17: frames in the agents' notes (Frames 2)
9
+
10
+ ### Changed
11
+
12
+ - The template's AGENTS.md follows cad's: joins between beams, screws into a slot, fittings, guides, jigs and a
13
+ frame's build.
14
+
8
15
  ## 0.3.16: screws through fixings in every template (Fixings 3)
9
16
 
10
17
  ### What reads fixings now
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-rulecad",
3
- "version": "0.3.16",
3
+ "version": "0.3.17",
4
4
  "description": "Start a rulecad project: npm create rulecad my-designs. A workspace with a soap tray to start from, ready to check, preview, export and share.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -93,6 +93,63 @@ variable says which rule it comes from. Follow these steps; they're what makes a
93
93
  drawn: one axis through the stack, a clearance hole in each part passed, a pilot, insert or nut at the far end, the
94
94
  length chosen from what is sold, thread engaged, the seat under the head and the key's way to it, and `cad list`
95
95
  counts the screws. Report what it finds with its numbers, and fix the part, never the relation, to make it pass.
96
+ - **Beams are held to each other by a join**, not a fasten: `{ "kind": "blind", "a": "y1.a", "b": "x1.back@120" }`
97
+ (`npx cad add join …`), `b` the place on the other beam where a's end meets it. A blind or end-tap join taps a's end,
98
+ drills b and adds its screw to the fasten checks and the list. A bracket, gusset or splice join with `"fitting":
99
+ "printed"` adds its printed fitting, sized from `"load"` (N, default 100) by finite elements, and its screws into both
100
+ beams' slots: report the fitting's grams, margin and stiffness from `cad check` with that load, and say the stiffness
101
+ leaves out the slot nuts. A bought fitting is a rule set named in `"fitting"` (`fitting-motedis-bracket-20-b6`;
102
+ bracket, gusset, splice, hidden and anchor joins): its screws and nuts are its set's, its price goes on `cad list`,
103
+ and its stiffness is its set's estimate, so report it as one. Choose printed or bought from what `cad list` costs
104
+ and what each stiffness rests on, and say both. A `fitting.fit` failure means the set is made for another profile
105
+ or slot: choose another set, never edit the set to pass. The other kinds are checked where they meet and say their
106
+ fitting comes later (`join.fitting`). Move the beam to fix `join.geometry`, never the address, unless the
107
+ address is what was wrong; `join.stiffness` says whether it rests on an estimate or on the joint rig's
108
+ measurement (and its date): report it as it says. A `join.drop` is a prediction for a beam held by one join, to
109
+ measure and write back with `cad measured`, never a figure to tune.
110
+ - **Beams are cut and drilled by hand from their sheets and jigs**: `npx cad beams <project>/<assembly>` writes a
111
+ cut-and-drill sheet per mark, and `--jigs` writes the jigs as a plate in `exports/` (a drill guide per distinct
112
+ hole across a beam, a tap guide per tapped end, a cut-length stop per length, a squaring corner of the hand each square join takes),
113
+ each marked with the marks it is for. Report each jig's grams and margin and that it prints clean; a hole too far
114
+ from both ends for one print is a `jig.drill` warning: say to mark it from the sheet. A `jig.tap` or `jig.square`
115
+ warning is a tapped end or a join with no jig that fits: tap it by eye, or square it with an engineer's square.
116
+ - **A bay closed by a sheet is a `panel` item**: `{ "id": "front", "panel": { "sheet": "acrylic", "thickness": 3,
117
+ "bay": ["x1", "z2", "x2", "z1"], "out": [0, -1, 0] } }`. It is cut to the bay with its clips at a pitch, each
118
+ fastened into its slot; report its size and grams from `cad check` (`panel.size`) and the clips from `cad list`.
119
+ `"door": { "hinge": "z1" }` makes it a door on two printed hinges, turning on a joint: run `cad check --sweep` and
120
+ report what it finds. A turn-button latch shown shut blocks the door in its first degree, which is right.
121
+ - **A board or supply on a frame is a bought item with `"mount"`**: `{ "id": "psu", "bought": "supply-24v",
122
+ "variant": "LRS-50-24", "mount": { "on": "rail.top@-90" } }`. Its holes come from its rule set (`mount_holes`, x then
123
+ y for each); add them from the maker's drawing, with their source, before mounting a device whose set has none. A
124
+ wire along a beam is a run in its `via`, `{ "along": "rail.front", "from": 300, "to": 60 }`: report its length and
125
+ its clips from `wire.length` and `wire.run`.
126
+ - **Linear motion on a beam is a guide**: `"guides": [{ "kind": "rail", "rail": "rail-mgn12", "carriage": "MGN12H",
127
+ "on": "x1.top", "from": 50, "length": 300 }]`. Never draw a rail or carriage yourself, nor type its screws: the
128
+ guide places the rail, its screws into the slot at its pitch and each carriage on a sliding joint with its true
129
+ travel. Fix a table on a carriage with a fixed joint at `g1-carriage-1.top`. Run `cad check --sweep`, and report
130
+ `guide.fit`, the travel and each carriage's `joint.moment` margin; a fail there means a longer carriage
131
+ (`MGN12H`), a larger rail or the load nearer the carriage, never a changed rating.
132
+ On a V-slot beam the same guide can be wheels: `{ "kind": "wheels", "wheel": "v-wheel-solid", "on": "x1.top",
133
+ "from": 50, "length": 400 }` (the plate over that face, its wheels in the tracks either side). A plain T-slot is
134
+ refused for wheels: use a rail or a `slider` there. Report the wheels' `guide.fit` seat, the travel and the
135
+ plate's `joint.moment` margin, and say the wheels' ratings are estimates.
136
+ Two smooth rods and a lead screw are two guides: `{ "kind": "rods", "on": "x1.top", "from": 60, "length": 101,
137
+ "endstop": { "at": "x1.front@82" } }` and `{ "kind": "screw", "guide": "g1", "motor": { "model": "28byj48" } }`.
138
+ Never draw the holders, motor plate, coupler or carriage yourself: the guides place them by addresses and give the
139
+ motor its lead screw. Report the travel, `motor.torque`'s margin, `guide.coupler`, the bearings' `joint.moment`, the
140
+ endstop's home, and each printed part's grams and margin; if the endstop is refused, use the address it names.
141
+ - **A part screwed onto a beam is a `fasten` into a slot**: `"into": "x1.top"` (or `x1.top.2`, or `x1.top@120`, the
142
+ middle of its screws), the
143
+ part's holes drawn with `v.fixings` at the slot's spacing, `"nut"` the slot nut's kind. `fasten.slot` fails a hole off
144
+ a slot's centre line, with the distance: move the hole. `frame.nut` fails slide-in nuts in a slot that joins close
145
+ at both ends: use the kind it names (`"nut": "drop-in"`). `frame.preload` lists nuts to load before a join; tell
146
+ the user, and `cad order` shows them on the step.
147
+ - **A frame's build is `cad order`**: from bars to a square frame in numbered steps (cut, drill and tap, sides built
148
+ flat and squared, nuts to load, joins with their torque, the diagonals, then the rest). Give the user its steps and
149
+ its diagonals (`frame.square`: each and the difference to accept). If it is refused for a slot's nuts, change the
150
+ nut to the kind it names; never reorder the joins to get round it. Where a side is built on the frame, not flat,
151
+ the build says why; pass that on. Its load and "Slide ... screw into ... head first" steps give each nut and head a
152
+ way into its slot: pass them on as written. `cad check` counts the same steps.
96
153
  - A fit with `"fastens": true` is for what holds parts without screws (pins, a press, a clip). An older assembly with
97
154
  a holes fit (`{ "holes": "pcb.board", "into": "case.body", … }`) and a fit that fastens the same parts gets a
98
155
  `fasten.suggest` note from `cad check`: `npx cad add fasten <project>/<assembly> --from-fits` puts the fasten in