MustafaMulla29/rp2040-bldc-motor-controller-new
73×72 mm 4-layer USB‑C PD (5/9/15/20 V) RP2040 controller PCB with protected power switching, MCT8329A sensorless BLDC three-phase MOSFET bridge, USB data/programming, onboard controls, and three motor outputs feeding a 2212 motor through rigid bullet adapters.
- Version
- 0.3.100
- License
- unset
- Stars
- 0
assembly/vendor/README.md
# Local native cable extensions
These are source-built local extensions, not upstream releases. The PCB project and its validated geometry are unchanged. All packages are pinned as local archives in the assembly manifest and lockfile.
| Package | Base commit | Local version / change |
|---|---|---|
| @tscircuit/core | 6cb29ea80f3f71905bd78914ec17b95fd0d17e17 | 0.0.2110-bldc.4: explicit `fromMatingPoint`, `toMatingPoint`, and validated `wirePath`; rebuilt with the extended cableprinter |
| @tscircuit/cableprinter | f16c59e5ef66d4d587b28a76fd8d37e4b4c74e2c | 0.0.6-bldc.2: `wire_end_dNmm` for a permanently attached single insulated wire; `_colorRRGGBB` suffix |
| jscad-electronics | bce940e33c110e5397edcb482905ef2bd6e16170 | 0.0.211-bldc.1: renders a fixed wire end without connector geometry |
The core selectors still resolve real source owners. Explicit points and normalized outward directions use right-handed circuit-world millimetres (+X right, +Y top, +Z above). The native path solver and cable renderer remain in use. No placeholder PCB or motor is introduced.
A `wire_end` has bodyDepth=0, one wire, and width/height equal to the cable diameter. The schemas reject incompatible bundles and mismatched wire diameters. The renderer produces the wire all the way to the authored endpoint without a housing or strain relief there. Existing male/female bullet mesh generation is unchanged. Nothing is hidden or deleted after rendering.
Rebuild order:
1. Fetch the pinned cableprinter source, apply `cableprinter-wire-end.patch` then `cableprinter-wire-colour.patch`, set version 0.0.6-bldc.2, install, run `bun run build`, and pack. Its targeted tests pass 7/7.
2. Fetch pinned jscad-electronics, apply `jscad-electronics-wire-end.patch`, set version 0.0.211-bldc.1, install, build and pack. Run the new fixed-wire-end snapshots and existing bullet, adapter and endpoint tests: 8/8 pass. The source patch includes the snapshot test; generated test PNGs are kept outside the published package.
3. Fetch pinned core, apply `core-mating-points.patch` then `core-wire-path.patch`, set version 0.0.2110-bldc.4, and set BOTH its dev dependency and override for cableprinter to the new local archive before installing and building. Core bundles cableprinter. Run the five cable model/scope/mating/validation tests, then pack.
4. Install those archives through the assembly manifest and overrides. A clean install avoids old nested renderer copies; use `bun install --frozen-lockfile` for reproduction.
`core-mating-points.patch` is unchanged from the prior revision; the prior rebuild rebases it onto the released core 0.0.2110, using props 0.0.697 and the fixed-wire cable definition. Source patches contain tests; archives contain built JS and declarations. Motor wire geometry and rigid-adapter dimensions remain illustrative where the supplier has not provided dimensions.
The project now declares named connection ports in component-local coordinates (`attachments.ts`). `component-cable.tsx` resolves them through the same pose used for CAD. Adapter placement comes from the actual compiled PCB socket CAD, including its model origin; no socket world coordinates or phase-specific adapter meshes are duplicated. The world-point props above are the extension boundary only.
The full assembly also uses `wirePath`, a local optional polyline in world millimetres. Core rejects paths that miss either resolved wire exit by more than 0.001 mm, contain zero-length segments, or depart in the wrong direction. Its normal path inference is retained when the prop is absent. Native `cad_cable.path` and GLB export carry the entire route. The former battery/sensor cable assembly is removed; no gravity or obstacle solver is claimed.
The optional `_colorRRGGBB` cable-string suffix is limited to a single round wire and leaves endpoint definitions unchanged. Integration tests in `full-assembly.test.tsx` exercise the packaged extensions, real PCB pin mapping, endpoints, cable length, and rejection of invalid paths. Neither extension edits installed code or post-processes circuit JSON.