@rulecad/cad 0.7.45 → 0.7.46

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/EXAMPLES.md CHANGED
@@ -976,6 +976,9 @@ The check says which motor it is and how far a step moves (`0.0879° a step`, or
976
976
  on the pinion's axis, the force reaching the slide against the 1 N it has to push and how many times over, how fast the
977
977
  slide moves, and that the slide holds with the power off: the 28BYJ-48's own gearbox friction, far more than the load can
978
978
  turn it back with. The torque's line ends `(rests on community figures: measure it)`, because that's what its torque is.
979
+ `motor.mount` bends the rail under the motor by FE, held where its feet are screwed on: the shaft's tip moves a few
980
+ thousandths of a millimetre against the pinion's seat on the rail, far inside the 0.2 mm the pinion is drawn with. A NEMA 17 hung from a 2 mm PLA plate would
981
+ fail the same check, and say how thick the plate would need to be.
979
982
 
980
983
  ### The spool winder, driven
981
984
 
package/README.md CHANGED
@@ -417,7 +417,7 @@ An item can be a motor instead of a printed object: `{ "id": "drive", "motor": {
417
417
  - A compound planetary is a `planetary` with `"output": { "ring", "planet", "teeth" }`: a second ring on the planets' second step, following them in phase.
418
418
  - `motor.torque`: what reaches the joint through the gears, against the load: a fail under 1 times, a warning under the margin. It says what its figures rest on. `motor.speed`: how fast it moves and how long its range takes. Stages pass on `stageEfficiency` of the power (0.95 a mesh, an estimate).
419
419
  - `motor.holds`: with the power on (holding torque, or stall torque) and off (detent torque, a built-in gearbox's friction, a worm that locks, gears under 50% efficient, or `"brake": "a ratchet and pawl"` on the joint). Dropping with the power off is a warning: it may be what you want.
420
- - `motor.mount`: the part a motor is fastened to (a `fastens` fit), read as drawn: how thick it is at the screw holes against the screws' size, and the screws' bearing on the plastic under the motor's full torque. How far the whole part bends isn't checked yet.
420
+ - `motor.mount`: the part a motor is fastened to (a `fastens` fit), read as drawn: how thick it is at the screw holes against the screws' size, and the screws' bearing on the plastic under the motor's full torque. Then the whole part bent, by FE on the part as drawn (cubes, two across the plate at the screws): the motor's weight at its centre, along `gravity` in the pose it's checked in, and its full torque (the larger of its working and holding torque), both carried into the plate where the screws clamp it. The part is held at the joint that carries it, if one does; else where it meets the printed parts it's fastened to that sit below it; failing both, on its lowest face. It reports how far the shaft's tip moves (against the driven joint's seat, where that is on the same part, since the two move together), against the printer's `fit` clearance (or the motor's `"deflection"` in mm), and the peak stress against the material's `strength`; under 2 times either fails, and says what fixes it: the plate thickness that would do (bending goes with its cube), ribs, or how much stiffer a material would have to be. Cells this coarse read a plate 10 to 20% stiff, and a cell's stress is read at its centre, so the peak is scaled up to the surface; it's an estimate, said as one. Kept in `.cache/mount`.
421
421
  - `motor.heat`: the motor's case against the softening point of the material the project prints in. Too hot says the current to set the driver to.
422
422
  - A `"shaft": true` fit (or `"press"`) between a motor and what it drives reads the bore from the part as drawn: that it's on the shaft (`shaft.seat`), that its flat is there (`shaft.flat`; the shaft turns to meet it, so where the flat faces doesn't matter), how much of the flat it grips (`shaft.grip`), and, pressed on, the hoop stress in the hub (`shaft.hoop`).
423
423
  - `cad preview` of an assembly with a motor draws each one at work beside the picture, as SVG: `<assembly>-<motor>-curve.svg`, its torque against speed at the output with the load and the working speed marked, and `<assembly>-<motor>-train.svg`, the torque from its shaft through each stage to the joint with the load, against what the load needs there, and whether it holds with the power on and off. The numbers are the check's.
package/lib/motors.mjs CHANGED
@@ -7,6 +7,13 @@ import { motorModel, motorParts, mountModel, performance } from '@rulecad/motors
7
7
  import { stageEfficiency } from '@rulecad/gears';
8
8
  import { named } from './parts.mjs';
9
9
  import { referenceBuilt } from './bought.mjs';
10
+ import crypto from 'node:crypto';
11
+ import { grid as makeGrid, analyse, positions } from '@rulecad/fea';
12
+ import { threadsBackend } from '@rulecad/fea/threads';
13
+ import { host } from './host.mjs';
14
+ import { paths, printerOf } from './workspace.mjs';
15
+ import { peekRuleSet } from './rules.mjs';
16
+ import { solidFill } from './optimise.mjs';
10
17
 
11
18
  const require = createRequire(import.meta.url);
12
19
  const n3 = (x, d = 3) => String(Number(x.toFixed(d)));
@@ -194,7 +201,7 @@ export function motorChecks(s, f, helpers, materialName) {
194
201
  const slideRate = main.x.type === 'prismatic' ? (speedOut * 360 * main.t.slide) / 60 : null, span = slideRate ? main.x.dofs[0][1] - main.x.dofs[0][0] : 0, time = slideRate ? span / slideRate : 60 / speedOut; // along a slide's travel, or a turn
195
202
  f('info', `${main.x.id} moves at ${slideRate ? `${n3(slideRate, 2)} mm/s` : `${n3(speedOut, 2)} rpm`} with ${d.id} at ${n3(motorSpeed, 1)} rpm: ${slideRate ? 'its whole range' : 'a turn'} in ${n3(time, 1)} s`, null, { code: 'motor.speed', at: at(main.x), values: { rpm: speedOut, time } });
196
203
  }
197
- mountCheck(s, d, f, W, avail, materialName);
204
+ mountCheck(s, d, f, W, avail, materialName, { worlds, mul });
198
205
  // Does it hold?
199
206
  const fig = (k) => m.figures[k]?.value, kt = m.type === 'brushless' ? 60 / (2 * Math.PI * fig('kv')) : 0;
200
207
  const on = atCurrent(m, d.spec, fig('holding_torque') ?? fig('stall_torque') ?? (kt ? kt * fig('rated_current') : 0)), off_ = fig('detent_torque') ?? fig('friction_torque') ?? null, brake = lines.map((l) => motion.joints.find((x) => x.id === l.x.id)?.brake).find(Boolean) ?? motion.joints.find((x) => x.id === d.joint)?.brake;
@@ -216,8 +223,8 @@ export function motorChecks(s, f, helpers, materialName) {
216
223
  }
217
224
 
218
225
  // The part a motor is fastened to, under the motor's full torque as a reaction at its screws: how thick it is at the
219
- // holes (read from the part as drawn), and the screws' bearing on the plastic. Not yet: how far the whole part bends.
220
- function mountCheck(s, d, f, W, avail, materialName) {
226
+ // holes (read from the part as drawn), the screws' bearing on the plastic, and how far the whole part bends (mountBends).
227
+ function mountCheck(s, d, f, W, avail, materialName, frame) {
221
228
  const m = d.model, top = (n) => String(n).split(/[.@]/)[0], fit = s.fits.find((x) => x.fastens && [top(x.a), top(x.b)].includes(d.id));
222
229
  if (!fit || !m.mount.holes.length) return;
223
230
  const other = top(fit.a) === d.id ? top(fit.b) : top(fit.a), parts = s.parts.filter((p) => p.item === other || p.leaf === other);
@@ -230,6 +237,132 @@ function mountCheck(s, d, f, W, avail, materialName) {
230
237
  const here = mountModel(m, { plate: +plate.toFixed(2), ...(d.spec.screw ? { screw: d.spec.screw } : {}) }), mat = material(materialName) || material('pla'), radius = Math.max(...m.mount.holes.map(([x, y]) => Math.hypot(x, y))), each = avail / (m.mount.holes.length * radius / 1000), bearing = each / (hd * t), margin = mat.strength / bearing;
231
238
  for (const x of here.findings) f(x.level, `${d.id} on ${other}: ${x.text}`, x.level === 'pass' ? null : `${d.id}: ${x.code.split('.')[1]}`, { code: 'motor.mount' });
232
239
  f(margin < 2 ? 'fail' : 'pass', `${d.id} on ${other}: ${n3(plate, 2)} mm of plate at the screws, each taking ${n3(each, 1)} N against the torque (bearing ${n3(bearing, 1)} MPa, ${n3(margin, 0)} times under ${mat.name.toUpperCase()}'s ${mat.strength} MPa)`, margin < 2 ? `${d.id}: screws pull through` : null, { code: 'motor.mount', values: { plate, bearing, margin } });
240
+ mountBends(s, d, f, W, avail, mat, { other, parts, inv, plate, hd, ...frame });
241
+ }
242
+
243
+ // ---------- the mount, bent ----------
244
+ // The part as a whole under the motor: its weight (gravity as the assembly has it, in the pose it's checked in) at its
245
+ // centre and its full torque about the shaft, both carried into the part where the screws clamp it, by FE on the part as
246
+ // drawn (cubes, two across the plate at the screws). The part is held where it meets the printed parts it's fastened to,
247
+ // or at the joint it turns on; failing both, where it stands (its lowest face). Reported: how far the shaft's tip moves,
248
+ // against the printer's fit clearance (what the parts it drives are drawn with), and the peak stress against the
249
+ // material's strength. Kept in .cache, like the other FE checks.
250
+ const sub3 = (a, b) => [a[0] - b[0], a[1] - b[1], a[2] - b[2]], add3 = (a, b) => [a[0] + b[0], a[1] + b[1], a[2] + b[2]];
251
+ const len3 = (a) => Math.hypot(a[0], a[1], a[2]);
252
+ function box3(pts) { const lo = [Infinity, Infinity, Infinity], hi = [-Infinity, -Infinity, -Infinity]; for (const p of pts) for (let k = 0; k < 3; k++) { if (p[k] < lo[k]) lo[k] = p[k]; if (p[k] > hi[k]) hi[k] = p[k]; } return { lo, hi }; }
253
+ // A small dense solve (Gaussian elimination, partial pivoting); a pivot near nothing is held at a hair, not divided by
254
+ function solveSmall(A, b) {
255
+ const n = b.length, M = A.map((r, i) => [...r, b[i]]), big = Math.max(1e-30, ...A.map((r, i) => Math.abs(r[i])));
256
+ for (let c = 0; c < n; c++) {
257
+ let p = c; for (let r = c + 1; r < n; r++) if (Math.abs(M[r][c]) > Math.abs(M[p][c])) p = r;
258
+ [M[c], M[p]] = [M[p], M[c]]; if (Math.abs(M[c][c]) < 1e-12 * big) M[c][c] = 1e-12 * big;
259
+ for (let r = 0; r < n; r++) if (r !== c) { const k = M[r][c] / M[c][c]; for (let q = c; q <= n; q++) M[r][q] -= k * M[c][q]; }
260
+ }
261
+ return M.map((r, i) => r[n] / r[i]);
262
+ }
263
+
264
+ /**
265
+ * The FE itself, in the motor's frame (the mounting face at z = 0, the shaft along z). tris: the part; holes: the screws'
266
+ * [x, y]; hole: their diameter; held: boxes ({ lo, hi }) and balls ({ at, r }) where the part is held, or null for its
267
+ * lowest face along `down`; weight: N at `centre`, along `down`; torque: N mm about z; tip: the shaft's tip.
268
+ * @returns {{ deflection: number, stress: number, atHoles: boolean, cell: number, across: number, held: string } | { missing: string }}
269
+ */
270
+ export function mountFE({ tris, holes, hole, plate, side, held, down, weight, centre, torque, tip, ref = null, E, nu, budget = 9000 }) {
271
+ const key = crypto.createHash('sha256').update(JSON.stringify([3, tris, holes, hole, plate, side, held, down, weight, centre, torque, tip, ref, E, nu, budget])).digest('hex').slice(0, 24), file = paths.cache('mount', `${key}.json`);
272
+ if (!process.env.CAD_NO_CACHE && host.exists(file)) return JSON.parse(host.readText(file));
273
+ const { lo, hi } = box3(tris.flat()), span = sub3(hi, lo);
274
+ let cell = Math.max(0.4, plate / 2);
275
+ const count = (h) => span.reduce((t, x) => t * Math.max(1, Math.ceil(x / h)), 1);
276
+ while (count(cell) > budget) cell *= 1.1;
277
+ const n = span.map((x) => Math.max(1, Math.ceil(x / cell))), gr = { nx: n[0], ny: n[1], nz: n[2], h: cell };
278
+ const density = solidFill(tris, gr, lo), g = makeGrid(gr), at = positions(g), pos = (id) => add3(lo, at[id]), onPart = new Uint8Array(g.nodes);
279
+ for (let e = 0; e < density.length; e++) if (density[e] >= 0.5) for (let k = 0; k < 8; k++) onPart[g.edof[e * 24 + 3 * k] / 3] = 1;
280
+ // Clamped: the plate round each screw, under its head (about twice the hole across), through the plate's thickness
281
+ const grip = hole / 2 + Math.max(hole / 2, 1.5 * cell), clamp = [], hold = [];
282
+ const inHeld = (p) => held.some((b) => (b.r != null ? len3(sub3(p, b.at)) <= Math.max(b.r, 2.5 * cell) : p.every((x, k) => x >= b.lo[k] - cell && x <= b.hi[k] + cell)));
283
+ let lowest = Infinity; if (!held) for (const t of tris) for (const p of t) lowest = Math.min(lowest, -(p[0] * down[0] + p[1] * down[1] + p[2] * down[2]));
284
+ for (let id = 0; id < g.nodes; id++) {
285
+ if (!onPart[id]) continue;
286
+ const p = pos(id), z = p[2] * side; // (the screws' clamp first: a part held all over its face is still loaded at them)
287
+ if (z >= -cell && z <= plate + cell && holes.some(([x, y]) => Math.hypot(p[0] - x, p[1] - y) <= grip)) clamp.push(id);
288
+ else if (held ? inHeld(p) : -(p[0] * down[0] + p[1] * down[1] + p[2] * down[2]) <= lowest + cell * 0.75) hold.push(id);
289
+ }
290
+ const heldBy = !held ? 'on its lowest face' : held.some((b) => b.r != null) ? 'at the joint that carries it' : 'where it is fastened';
291
+ if (!hold.length) return { missing: `nothing of it is held ${heldBy}` };
292
+ if (!clamp.length) return { missing: 'the screws are where it is held', cell };
293
+ // The motor's weight and torque, shared over the clamped nodes as a rigid body would put them there
294
+ const P = clamp.map(pos), c = P.reduce((t, p) => add3(t, p), [0, 0, 0]).map((x) => x / P.length), R = P.map((p) => sub3(p, c));
295
+ const J = [[0, 0, 0], [0, 0, 0], [0, 0, 0]]; for (const r of R) { const rr = r[0] * r[0] + r[1] * r[1] + r[2] * r[2]; for (let a = 0; a < 3; a++) for (let b = 0; b < 3; b++) J[a][b] += (a === b ? rr : 0) - r[a] * r[b]; }
296
+ const Fw = down.map((x) => x * weight), arm = sub3(centre, c), Mw = cross(arm, Fw);
297
+ const loads = [1, -1].map((sign) => {
298
+ const M = [Mw[0], Mw[1], Mw[2] + sign * torque], w = solveSmall(J, M), out = new Float64Array(g.dofs);
299
+ clamp.forEach((id, i) => { const t = cross(w, R[i]); for (let k = 0; k < 3; k++) out[3 * id + k] = Fw[k] / clamp.length + t[k]; });
300
+ return out;
301
+ });
302
+ const fixed = new Uint8Array(g.dofs); for (const id of hold) for (let k = 0; k < 3; k++) fixed[3 * id + k] = 1;
303
+ let a; try { a = analyse({ grid: g, density, material: { E, nu }, fixed, loads, backend: threadsBackend }); } catch (e) { return { missing: e.code === 'fea.unheld' ? `it isn't held still ${heldBy}` : e.message, cell }; }
304
+ // The motor moves as a rigid body with the clamped plate: the best fit of a shift and a small turn, at the shaft's tip
305
+ // Where the driven joint stands on this same part, the shaft is measured against the part there (they move together)
306
+ let base = null;
307
+ if (ref) { let best = Infinity; for (let id = 0; id < g.nodes; id++) if (onPart[id]) best = Math.min(best, len3(sub3(pos(id), ref))); base = []; for (let id = 0; id < g.nodes; id++) if (onPart[id] && len3(sub3(pos(id), ref)) <= best + cell) base.push(id); }
308
+ const rigid = (u) => {
309
+ const A = Array.from({ length: 6 }, () => new Array(6).fill(0)), b = new Array(6).fill(0);
310
+ clamp.forEach((id, i) => {
311
+ const [x, y, z] = R[i], rows = [[1, 0, 0, 0, z, -y], [0, 1, 0, -z, 0, x], [0, 0, 1, y, -x, 0]]; // u = t + θ × r
312
+ rows.forEach((row, k) => { for (let p = 0; p < 6; p++) { b[p] += row[p] * u[3 * id + k]; for (let q = 0; q < 6; q++) A[p][q] += row[p] * row[q]; } });
313
+ });
314
+ const s6 = solveSmall(A, b), moved = add3(s6.slice(0, 3), cross(s6.slice(3), sub3(tip, c)));
315
+ return len3(base ? sub3(moved, [0, 1, 2].map((q) => base.reduce((t, id) => t + u[3 * id + q], 0) / base.length)) : moved);
316
+ };
317
+ const deflection = Math.max(...a.u.map(rigid));
318
+ // A cell's stress is read at its centre, inside the surface: across k cells, bending reads (k - 1) / k of the surface's
319
+ const across = Math.max(2, Math.round(plate / cell)), lift = across / (across - 1);
320
+ let stress = 0, atHoles = false;
321
+ for (const st of a.stress) for (let e = 0; e < density.length; e++) {
322
+ if (density[e] < 0.5 || st[e] * lift <= stress) continue;
323
+ const p = add3(lo, [((e % n[0]) + 0.5) * cell, ((Math.floor(e / n[0]) % n[1]) + 0.5) * cell, (Math.floor(e / (n[0] * n[1])) + 0.5) * cell]);
324
+ stress = st[e] * lift; atHoles = holes.some(([x, y]) => Math.hypot(p[0] - x, p[1] - y) <= grip + cell);
325
+ }
326
+ const out = { deflection, relative: !!base, stress, atHoles, cell, across, held: heldBy, cells: g.cells };
327
+ host.writeText(file, JSON.stringify(out)); return out;
328
+ }
329
+
330
+ function mountBends(s, d, f, W, avail, mat, { other, parts, inv, plate, hd, worlds, mul }) {
331
+ const m = d.model, top = (x) => String(x).split(/[.@]/)[0], motion = s.motion, ids = motion.items.map((x) => x[0]);
332
+ if (!(mat?.modulus > 0) || !(mat?.strength > 0)) return;
333
+ const tris = parts.filter((p) => p.role !== 'support').flatMap((p) => p.triangles.map((t) => t.map(inv)));
334
+ // Where it's held: at the joint it hangs from, if it's carried by one (fixed to a link, or turning on a joint); else at
335
+ // the printed parts it's fastened to that sit below it (along gravity), not the motor nor anything bought
336
+ const g = motion.gravity || [0, 0, -1], gl = Math.hypot(...g) || 1, down = [0, 1, 2].map((r) => (W[r] * g[0] + W[4 + r] * g[1] + W[8 + r] * g[2]) / gl);
337
+ const k = ids.indexOf(other), from = motion.joints.find((j) => j.child === k), boxes = [];
338
+ if (from && worlds) boxes.push({ at: inv(axisOf(motion, worlds, from, mul).O), r: 8 });
339
+ else {
340
+ const motors = new Set((motion.drives || []).map((x) => x.id)), mine = box3(tris.flat()), depth = (b) => [0, 1, 2].reduce((t, q) => t + ((b.lo[q] + b.hi[q]) / 2) * down[q], 0);
341
+ for (const x of s.fits) {
342
+ if (!x.fastens || ![top(x.a), top(x.b)].includes(other)) continue;
343
+ const them = top(x.a) === other ? top(x.b) : top(x.a); if (them === d.id || motors.has(them)) continue;
344
+ const theirs = s.parts.filter((p) => (p.item === them || p.leaf === them) && p.role !== 'reference' && p.role !== 'support');
345
+ const b = theirs.length && box3(theirs.flatMap((p) => p.triangles.flat().map(inv)));
346
+ if (b && depth(b) > depth(mine)) boxes.push(b);
347
+ }
348
+ }
349
+ const fig = (x) => m.figures[x]?.value, hold = atCurrent(m, d.spec, fig('holding_torque') ?? fig('stall_torque') ?? 0), T = Math.max(avail, hold); // N m: the most it can put on its screws
350
+ const side = m.mount.side, centre = [m.body.centre[0], m.body.centre[1], (-side * m.body.length) / 2], tip = m.anchors.tip?.origin ?? [0, 0, m.shaft.tip];
351
+ const driven = motion.joints.find((j) => j.id === d.joint), ref = driven && driven.parent === k && worlds ? inv(axisOf(motion, worlds, driven, mul).O) : null;
352
+ const fe = mountFE({ tris, holes: m.mount.holes, hole: hd, plate, side, held: boxes.length ? boxes : null, down, weight: (m.mass ?? 0) * G, centre, torque: T * 1000, tip, ref, E: mat.modulus, nu: mat.poisson ?? 0.36 });
353
+ const S = rowsAt(W, tip), refs = { item: d.id, part: other }, name = mat.name.toUpperCase();
354
+ if (fe.missing) return f('warn', `${d.id} on ${other}: couldn't bend the part under the motor: ${fe.missing}. Fasten it to what holds it (a "fastens" fit)`, `${d.id}: mount not solved`, { code: 'motor.mount', at: S, refs });
355
+ let limit = 0.2; try { limit = d.spec.deflection != null ? s.num(d.spec.deflection) : peekRuleSet(printerOf(s.project)).rules.fit?.value ?? 0.2; } catch {}
356
+ const bend = limit / Math.max(fe.deflection, 1e-9), strong = mat.strength / Math.max(fe.stress, 1e-9), margin = Math.min(bend, strong), K = 2, bad = margin < K;
357
+ const where = fe.atHoles ? 'at the screw holes' : 'in the part, away from the screws';
358
+ const how = `FE on ${n3(fe.cell, 2)} mm cubes, ${fe.across} across the plate, held ${fe.held}; an estimate: cells this coarse read a plate 10 to 20% stiffer than it is`;
359
+ const said = `${d.id} on ${other}: under the motor's ${n3((m.mass ?? 0) * 1000, 0)} g and ${n3(T, 3)} N m, the shaft's tip moves ${n3(fe.deflection, 3)} mm${fe.relative ? ` against ${d.joint}'s seat on ${other}` : ''}, ${bend >= 1 ? `${n3(bend, 1)} times inside` : `${n3(1 / bend, 1)} times`} the ${n3(limit, 2)} mm fit the parts it drives are drawn with, and the stress peaks at ${n3(fe.stress, 2)} MPa ${where}, ${strong >= 1 ? `${n3(strong, 1)} times under` : `${n3(1 / strong, 1)} times`} ${name}'s ${mat.strength} MPa (${how})`;
360
+ let fix = '';
361
+ if (bad) {
362
+ const grow = Math.max(bend < K ? Math.cbrt(K / bend) : 1, strong < K ? Math.sqrt(K / strong) : 1), want = Math.ceil(plate * grow * 5) / 5; // bending goes with the cube of the thickness, stress with its square
363
+ fix = `. A plate about ${n3(want, 1)} mm thick where it bends (${n3(plate, 2)} mm at the screws now), or ribs under it, or a stiffer material (${bend < K ? `${n3((K / bend), 1)} times ${name}'s ${mat.modulus} MPa modulus` : `${n3((mat.strength * K) / strong, 0)} MPa strength or more`}), or hold it closer to the motor`;
364
+ }
365
+ f(bad ? 'fail' : 'pass', said + fix, bad ? `${d.id}: mount ${bend < strong ? 'bends' : 'overstressed'} ${n3(margin, 1)}×` : null, { code: 'motor.mount', at: S, refs, values: { deflection: fe.deflection, relative: fe.relative, limit, stress: fe.stress, strength: mat.strength, margin, cell: fe.cell, held: fe.held } });
233
366
  }
234
367
 
235
368
  // A "shaft" fit: a motor's shaft in the bore of a part. Reads the bore from the part as drawn: a slice across the
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rulecad/cad",
3
- "version": "0.7.45",
3
+ "version": "0.7.46",
4
4
  "description": "The cad command: JSCAD designs from traceable rules, checked for printing and fit, versioned by what fits, shared as links and exported as Bambu 3MF.",
5
5
  "type": "module",
6
6
  "bin": {