@vcad/mcp 0.10.0-main.93 → 0.10.0-main.95
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/README.md +1 -1
- package/index.mjs +186 -83
- package/package.json +3 -3
- package/vcad_kernel_wasm_bg.wasm +0 -0
package/README.md
CHANGED
|
@@ -6,4 +6,4 @@ vcad's MCP server as a self-contained bundle (server + BRep kernel WASM).
|
|
|
6
6
|
{ "mcpServers": { "vcad": { "command": "npx", "args": ["-y", "@vcad/mcp"] } } }
|
|
7
7
|
```
|
|
8
8
|
|
|
9
|
-
Built from
|
|
9
|
+
Built from 2182e0fa666586bfac3ebff40ad17af91836bf97 at 2026-10-17T19:27:56.972Z. Source: https://github.com/ecto/vcad
|
package/index.mjs
CHANGED
|
@@ -4540,7 +4540,7 @@ function __wbg_get_imports() {
|
|
|
4540
4540
|
const a = state0.a;
|
|
4541
4541
|
state0.a = 0;
|
|
4542
4542
|
try {
|
|
4543
|
-
return
|
|
4543
|
+
return wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___js_sys_7c82484d4a1d6091___Function_fn_wasm_bindgen_d8ba3021eaa32f54___JsValue_____wasm_bindgen_d8ba3021eaa32f54___sys__Undefined___js_sys_7c82484d4a1d6091___Function_fn_wasm_bindgen_d8ba3021eaa32f54___JsValue_____wasm_bindgen_d8ba3021eaa32f54___sys__Undefined_______true_(a, state0.b, arg02, arg12);
|
|
4544
4544
|
} finally {
|
|
4545
4545
|
state0.a = a;
|
|
4546
4546
|
}
|
|
@@ -4578,7 +4578,7 @@ function __wbg_get_imports() {
|
|
|
4578
4578
|
const a = state0.a;
|
|
4579
4579
|
state0.a = 0;
|
|
4580
4580
|
try {
|
|
4581
|
-
return
|
|
4581
|
+
return wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___js_sys_7c82484d4a1d6091___Function_fn_wasm_bindgen_d8ba3021eaa32f54___JsValue_____wasm_bindgen_d8ba3021eaa32f54___sys__Undefined___js_sys_7c82484d4a1d6091___Function_fn_wasm_bindgen_d8ba3021eaa32f54___JsValue_____wasm_bindgen_d8ba3021eaa32f54___sys__Undefined_______true_(a, state0.b, arg02, arg12);
|
|
4582
4582
|
} finally {
|
|
4583
4583
|
state0.a = a;
|
|
4584
4584
|
}
|
|
@@ -5368,23 +5368,23 @@ function __wbg_get_imports() {
|
|
|
5368
5368
|
}, arguments);
|
|
5369
5369
|
},
|
|
5370
5370
|
__wbindgen_generic_0000000000000001: function(arg0, arg1) {
|
|
5371
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
5371
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wasm_bindgen_d8ba3021eaa32f54___JsValue__core_37ee0ce0c4cd57d5___result__Result_____wasm_bindgen_d8ba3021eaa32f54___JsError___true_);
|
|
5372
5372
|
return ret;
|
|
5373
5373
|
},
|
|
5374
5374
|
__wbindgen_generic_0000000000000002: function(arg0, arg1) {
|
|
5375
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
5375
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wasm_bindgen_d8ba3021eaa32f54___sys__JsNullable_wgpu_f894171a91484cea___backend__webgpu__webgpu_sys__gen_GpuError__GpuError___core_37ee0ce0c4cd57d5___result__Result_____wasm_bindgen_d8ba3021eaa32f54___JsError___true_);
|
|
5376
5376
|
return ret;
|
|
5377
5377
|
},
|
|
5378
5378
|
__wbindgen_generic_0000000000000003: function(arg0, arg1) {
|
|
5379
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
5379
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wgpu_f894171a91484cea___backend__webgpu__webgpu_sys__gen_GpuDeviceLostInfo__GpuDeviceLostInfo______true_);
|
|
5380
5380
|
return ret;
|
|
5381
5381
|
},
|
|
5382
5382
|
__wbindgen_generic_0000000000000004: function(arg0, arg1) {
|
|
5383
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
5383
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wasm_bindgen_d8ba3021eaa32f54___sys__JsNullable_wgpu_f894171a91484cea___backend__webgpu__webgpu_sys__gen_GpuError__GpuError___core_37ee0ce0c4cd57d5___result__Result_____wasm_bindgen_d8ba3021eaa32f54___JsError___true__440);
|
|
5384
5384
|
return ret;
|
|
5385
5385
|
},
|
|
5386
5386
|
__wbindgen_generic_0000000000000005: function(arg0, arg1) {
|
|
5387
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
5387
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wasm_bindgen_d8ba3021eaa32f54___sys__JsNullable_wgpu_f894171a91484cea___backend__webgpu__webgpu_sys__gen_GpuError__GpuError___core_37ee0ce0c4cd57d5___result__Result_____wasm_bindgen_d8ba3021eaa32f54___JsError___true__441);
|
|
5388
5388
|
return ret;
|
|
5389
5389
|
},
|
|
5390
5390
|
__wbindgen_generic_0000000000000006: function(arg0) {
|
|
@@ -5458,35 +5458,35 @@ function __wbg_get_imports() {
|
|
|
5458
5458
|
"./vcad_kernel_wasm_bg.js": import0
|
|
5459
5459
|
};
|
|
5460
5460
|
}
|
|
5461
|
-
function
|
|
5462
|
-
wasm.
|
|
5461
|
+
function wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wgpu_f894171a91484cea___backend__webgpu__webgpu_sys__gen_GpuDeviceLostInfo__GpuDeviceLostInfo______true_(arg0, arg1, arg2) {
|
|
5462
|
+
wasm.wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wgpu_f894171a91484cea___backend__webgpu__webgpu_sys__gen_GpuDeviceLostInfo__GpuDeviceLostInfo______true_(arg0, arg1, arg2);
|
|
5463
5463
|
}
|
|
5464
|
-
function
|
|
5465
|
-
const ret = wasm.
|
|
5464
|
+
function wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wasm_bindgen_d8ba3021eaa32f54___JsValue__core_37ee0ce0c4cd57d5___result__Result_____wasm_bindgen_d8ba3021eaa32f54___JsError___true_(arg0, arg1, arg2) {
|
|
5465
|
+
const ret = wasm.wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wasm_bindgen_d8ba3021eaa32f54___JsValue__core_37ee0ce0c4cd57d5___result__Result_____wasm_bindgen_d8ba3021eaa32f54___JsError___true_(arg0, arg1, arg2);
|
|
5466
5466
|
if (ret[1]) {
|
|
5467
5467
|
throw takeFromExternrefTable0(ret[0]);
|
|
5468
5468
|
}
|
|
5469
5469
|
}
|
|
5470
|
-
function
|
|
5471
|
-
const ret = wasm.
|
|
5470
|
+
function wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wasm_bindgen_d8ba3021eaa32f54___sys__JsNullable_wgpu_f894171a91484cea___backend__webgpu__webgpu_sys__gen_GpuError__GpuError___core_37ee0ce0c4cd57d5___result__Result_____wasm_bindgen_d8ba3021eaa32f54___JsError___true_(arg0, arg1, arg2) {
|
|
5471
|
+
const ret = wasm.wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wasm_bindgen_d8ba3021eaa32f54___sys__JsNullable_wgpu_f894171a91484cea___backend__webgpu__webgpu_sys__gen_GpuError__GpuError___core_37ee0ce0c4cd57d5___result__Result_____wasm_bindgen_d8ba3021eaa32f54___JsError___true_(arg0, arg1, arg2);
|
|
5472
5472
|
if (ret[1]) {
|
|
5473
5473
|
throw takeFromExternrefTable0(ret[0]);
|
|
5474
5474
|
}
|
|
5475
5475
|
}
|
|
5476
|
-
function
|
|
5477
|
-
const ret = wasm.
|
|
5476
|
+
function wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wasm_bindgen_d8ba3021eaa32f54___sys__JsNullable_wgpu_f894171a91484cea___backend__webgpu__webgpu_sys__gen_GpuError__GpuError___core_37ee0ce0c4cd57d5___result__Result_____wasm_bindgen_d8ba3021eaa32f54___JsError___true__440(arg0, arg1, arg2) {
|
|
5477
|
+
const ret = wasm.wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wasm_bindgen_d8ba3021eaa32f54___sys__JsNullable_wgpu_f894171a91484cea___backend__webgpu__webgpu_sys__gen_GpuError__GpuError___core_37ee0ce0c4cd57d5___result__Result_____wasm_bindgen_d8ba3021eaa32f54___JsError___true__440(arg0, arg1, arg2);
|
|
5478
5478
|
if (ret[1]) {
|
|
5479
5479
|
throw takeFromExternrefTable0(ret[0]);
|
|
5480
5480
|
}
|
|
5481
5481
|
}
|
|
5482
|
-
function
|
|
5483
|
-
const ret = wasm.
|
|
5482
|
+
function wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wasm_bindgen_d8ba3021eaa32f54___sys__JsNullable_wgpu_f894171a91484cea___backend__webgpu__webgpu_sys__gen_GpuError__GpuError___core_37ee0ce0c4cd57d5___result__Result_____wasm_bindgen_d8ba3021eaa32f54___JsError___true__441(arg0, arg1, arg2) {
|
|
5483
|
+
const ret = wasm.wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___wasm_bindgen_d8ba3021eaa32f54___sys__JsNullable_wgpu_f894171a91484cea___backend__webgpu__webgpu_sys__gen_GpuError__GpuError___core_37ee0ce0c4cd57d5___result__Result_____wasm_bindgen_d8ba3021eaa32f54___JsError___true__441(arg0, arg1, arg2);
|
|
5484
5484
|
if (ret[1]) {
|
|
5485
5485
|
throw takeFromExternrefTable0(ret[0]);
|
|
5486
5486
|
}
|
|
5487
5487
|
}
|
|
5488
|
-
function
|
|
5489
|
-
wasm.
|
|
5488
|
+
function wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___js_sys_7c82484d4a1d6091___Function_fn_wasm_bindgen_d8ba3021eaa32f54___JsValue_____wasm_bindgen_d8ba3021eaa32f54___sys__Undefined___js_sys_7c82484d4a1d6091___Function_fn_wasm_bindgen_d8ba3021eaa32f54___JsValue_____wasm_bindgen_d8ba3021eaa32f54___sys__Undefined_______true_(arg0, arg1, arg2, arg3) {
|
|
5489
|
+
wasm.wasm_bindgen_d8ba3021eaa32f54___convert__closures_____invoke___js_sys_7c82484d4a1d6091___Function_fn_wasm_bindgen_d8ba3021eaa32f54___JsValue_____wasm_bindgen_d8ba3021eaa32f54___sys__Undefined___js_sys_7c82484d4a1d6091___Function_fn_wasm_bindgen_d8ba3021eaa32f54___JsValue_____wasm_bindgen_d8ba3021eaa32f54___sys__Undefined_______true_(arg0, arg1, arg2, arg3);
|
|
5490
5490
|
}
|
|
5491
5491
|
function addToExternrefTable0(obj) {
|
|
5492
5492
|
const idx = wasm.__externref_table_alloc();
|
|
@@ -31224,6 +31224,68 @@ var init_ecad_sync = __esm({
|
|
|
31224
31224
|
}
|
|
31225
31225
|
});
|
|
31226
31226
|
|
|
31227
|
+
// ../core/dist/utils/pcb-layers.js
|
|
31228
|
+
function isCopperLayer(layer) {
|
|
31229
|
+
return COPPER_RE.test(layer);
|
|
31230
|
+
}
|
|
31231
|
+
function innerCopperIndex(layer) {
|
|
31232
|
+
const m = COPPER_RE.exec(layer);
|
|
31233
|
+
return m?.[2] ? Number(m[2]) : 0;
|
|
31234
|
+
}
|
|
31235
|
+
function innerCopperLayerName(n) {
|
|
31236
|
+
return `In${n}Cu`;
|
|
31237
|
+
}
|
|
31238
|
+
function copperLayerNames(count) {
|
|
31239
|
+
if (!Number.isInteger(count) || count < 1) {
|
|
31240
|
+
throw new Error(`invalid copper layer count ${count}`);
|
|
31241
|
+
}
|
|
31242
|
+
if (count === 1)
|
|
31243
|
+
return ["FCu"];
|
|
31244
|
+
const inner = Array.from({ length: count - 2 }, (_, i) => innerCopperLayerName(i + 1));
|
|
31245
|
+
return ["FCu", ...inner, "BCu"];
|
|
31246
|
+
}
|
|
31247
|
+
function assertSupportedCopperCount(count) {
|
|
31248
|
+
const ok4 = Number.isInteger(count) && count >= 1 && (count === 1 || count % 2 === 0) && count <= MAX_COPPER_LAYERS;
|
|
31249
|
+
if (!ok4) {
|
|
31250
|
+
throw new Error(`unsupported PCB layer count ${count}: expected 1 or an even number from 2 to ${MAX_COPPER_LAYERS}`);
|
|
31251
|
+
}
|
|
31252
|
+
}
|
|
31253
|
+
function copperSortKey(layer) {
|
|
31254
|
+
if (layer === "FCu")
|
|
31255
|
+
return 0;
|
|
31256
|
+
if (layer === "BCu")
|
|
31257
|
+
return Number.MAX_SAFE_INTEGER;
|
|
31258
|
+
return innerCopperIndex(layer);
|
|
31259
|
+
}
|
|
31260
|
+
function boardCopperLayers(pcb) {
|
|
31261
|
+
const seen = /* @__PURE__ */ new Set();
|
|
31262
|
+
const add = (l) => {
|
|
31263
|
+
if (l && isCopperLayer(l))
|
|
31264
|
+
seen.add(l);
|
|
31265
|
+
};
|
|
31266
|
+
for (const l of pcb?.stackup?.layers ?? [])
|
|
31267
|
+
add(l.layer);
|
|
31268
|
+
for (const t2 of pcb?.traces ?? [])
|
|
31269
|
+
add(t2.layer);
|
|
31270
|
+
for (const z of pcb?.zones ?? [])
|
|
31271
|
+
add(z.layer);
|
|
31272
|
+
for (const v of pcb?.vias ?? []) {
|
|
31273
|
+
add(v.startLayer);
|
|
31274
|
+
add(v.endLayer);
|
|
31275
|
+
}
|
|
31276
|
+
if (seen.size === 0)
|
|
31277
|
+
return ["FCu", "BCu"];
|
|
31278
|
+
return [...seen].sort((a, b) => copperSortKey(a) - copperSortKey(b));
|
|
31279
|
+
}
|
|
31280
|
+
var COPPER_RE, MAX_COPPER_LAYERS;
|
|
31281
|
+
var init_pcb_layers = __esm({
|
|
31282
|
+
"../core/dist/utils/pcb-layers.js"() {
|
|
31283
|
+
"use strict";
|
|
31284
|
+
COPPER_RE = /^(FCu|BCu|In(\d+)Cu)$/;
|
|
31285
|
+
MAX_COPPER_LAYERS = 32;
|
|
31286
|
+
}
|
|
31287
|
+
});
|
|
31288
|
+
|
|
31227
31289
|
// ../core/dist/stores/document-store.js
|
|
31228
31290
|
function crdtF64(v) {
|
|
31229
31291
|
return { F64: v };
|
|
@@ -31466,6 +31528,7 @@ var init_document_store = __esm({
|
|
|
31466
31528
|
init_ui_store();
|
|
31467
31529
|
init_parameters_store();
|
|
31468
31530
|
init_ecad_sync();
|
|
31531
|
+
init_pcb_layers();
|
|
31469
31532
|
_sceneSettingsFeatureId = null;
|
|
31470
31533
|
_schematicFeatureId = null;
|
|
31471
31534
|
_analysisStudiesFeatureId = null;
|
|
@@ -32572,26 +32635,13 @@ var init_document_store = __esm({
|
|
|
32572
32635
|
const traceWidth = options?.traceWidth ?? 0.15;
|
|
32573
32636
|
const clearance = options?.clearance ?? 0.15;
|
|
32574
32637
|
const boardName2 = options?.name ?? "PCB Board";
|
|
32575
|
-
|
|
32576
|
-
|
|
32577
|
-
|
|
32578
|
-
|
|
32579
|
-
|
|
32580
|
-
const dielectricPerLayer = thickness / (layerCount - 1);
|
|
32581
|
-
for (let i = 0; i < innerCount; i++) {
|
|
32582
|
-
stackupLayers.push({
|
|
32583
|
-
layer: innerLayerNames[i],
|
|
32584
|
-
copperThickness: 0.035,
|
|
32585
|
-
dielectricThickness: dielectricPerLayer,
|
|
32586
|
-
dielectricEr: 4.5,
|
|
32587
|
-
material: "FR4"
|
|
32588
|
-
});
|
|
32589
|
-
}
|
|
32590
|
-
}
|
|
32591
|
-
stackupLayers.push({
|
|
32592
|
-
layer: "BCu",
|
|
32638
|
+
assertSupportedCopperCount(layerCount);
|
|
32639
|
+
const copperNames = copperLayerNames(layerCount);
|
|
32640
|
+
const dielectricPerLayer = layerCount > 1 ? thickness / (layerCount - 1) : thickness;
|
|
32641
|
+
const stackupLayers = copperNames.map((layer, i) => i === 0 ? { layer, copperThickness: 0.035 } : {
|
|
32642
|
+
layer,
|
|
32593
32643
|
copperThickness: 0.035,
|
|
32594
|
-
dielectricThickness:
|
|
32644
|
+
dielectricThickness: dielectricPerLayer,
|
|
32595
32645
|
dielectricEr: 4.5,
|
|
32596
32646
|
material: "FR4"
|
|
32597
32647
|
});
|
|
@@ -41713,6 +41763,84 @@ var init_CHANGELOG = __esm({
|
|
|
41713
41763
|
CHANGELOG_default = {
|
|
41714
41764
|
$schema: "./changelog.schema.json",
|
|
41715
41765
|
entries: [
|
|
41766
|
+
{
|
|
41767
|
+
id: "2026-10-17-tessellate-bspline-bilinear-dispatch",
|
|
41768
|
+
version: "0.10.0",
|
|
41769
|
+
date: "2026-10-17",
|
|
41770
|
+
category: "fix",
|
|
41771
|
+
title: "B-spline and bilinear faces no longer tessellate flat",
|
|
41772
|
+
summary: "Both solid tessellation entry points sent B-spline and bilinear faces to the planar fan, flattening curved faces to their boundary polygon; they now use the true-surface tessellators.",
|
|
41773
|
+
features: [
|
|
41774
|
+
"tessellation",
|
|
41775
|
+
"nurbs",
|
|
41776
|
+
"kernel"
|
|
41777
|
+
]
|
|
41778
|
+
},
|
|
41779
|
+
{
|
|
41780
|
+
id: "2026-10-17-pcb-layer-coverage",
|
|
41781
|
+
version: "0.10.0",
|
|
41782
|
+
date: "2026-10-17",
|
|
41783
|
+
category: "fix",
|
|
41784
|
+
title: "Inner copper beyond In2Cu renders on 6\u201310 layer boards",
|
|
41785
|
+
summary: "Layer colours, toggles, dielectric slabs and copper Z now derive from the board stackup, so In3Cu\u2013In8Cu draw and toggle; new boards up to 10 layers get valid layer names; MCP accepts In7/In8.",
|
|
41786
|
+
features: [
|
|
41787
|
+
"pcb",
|
|
41788
|
+
"electronics",
|
|
41789
|
+
"layers"
|
|
41790
|
+
],
|
|
41791
|
+
mcpTools: [
|
|
41792
|
+
"get_copper",
|
|
41793
|
+
"render_stackup"
|
|
41794
|
+
]
|
|
41795
|
+
},
|
|
41796
|
+
{
|
|
41797
|
+
id: "2026-10-17-pcb-32-copper-layers",
|
|
41798
|
+
version: "0.10.0",
|
|
41799
|
+
date: "2026-10-17",
|
|
41800
|
+
category: "fix",
|
|
41801
|
+
title: "PCB: all 32 KiCad copper layers (In1..In30)",
|
|
41802
|
+
summary: "The PCB IR now carries In1Cu..In30Cu; DRC/DFM layer masks widened to 32 bits so copper on layers past In8 is no longer an unconnected island.",
|
|
41803
|
+
features: [
|
|
41804
|
+
"pcb",
|
|
41805
|
+
"ecad",
|
|
41806
|
+
"drc",
|
|
41807
|
+
"ir"
|
|
41808
|
+
]
|
|
41809
|
+
},
|
|
41810
|
+
{
|
|
41811
|
+
id: "2026-10-17-kicad-import-wildcard-layers",
|
|
41812
|
+
version: "0.10.0",
|
|
41813
|
+
date: "2026-10-17",
|
|
41814
|
+
category: "fix",
|
|
41815
|
+
title: "KiCad import: THT pads, multi-layer zones, arcs",
|
|
41816
|
+
summary: "KiCad import expands *.Cu / F&B.Cu / *.Mask against the board's stack (THT pads were importing with no copper), splits multi-layer zones, imports arc tracks and In9-In30, and warns instead of dropping.",
|
|
41817
|
+
features: [
|
|
41818
|
+
"pcb",
|
|
41819
|
+
"ecad",
|
|
41820
|
+
"kicad",
|
|
41821
|
+
"import",
|
|
41822
|
+
"drc"
|
|
41823
|
+
],
|
|
41824
|
+
mcpTools: [
|
|
41825
|
+
"import_kicad"
|
|
41826
|
+
]
|
|
41827
|
+
},
|
|
41828
|
+
{
|
|
41829
|
+
id: "2026-10-17-gerber-filefunction-stack-numbering",
|
|
41830
|
+
version: "0.10.0",
|
|
41831
|
+
date: "2026-10-17",
|
|
41832
|
+
category: "fix",
|
|
41833
|
+
title: "Gerber: number copper layers by real stack position",
|
|
41834
|
+
summary: "Gerber .FileFunction now numbers copper L1 (top) to Ln (bottom) for the board's layer count; B.Cu on a 4-layer board was tagged L2, colliding with In1.Cu.",
|
|
41835
|
+
features: [
|
|
41836
|
+
"pcb",
|
|
41837
|
+
"gerber",
|
|
41838
|
+
"export"
|
|
41839
|
+
],
|
|
41840
|
+
mcpTools: [
|
|
41841
|
+
"export_gerber"
|
|
41842
|
+
]
|
|
41843
|
+
},
|
|
41716
41844
|
{
|
|
41717
41845
|
id: "2026-10-16-root-cache-rigid-placement",
|
|
41718
41846
|
version: "0.10.0",
|
|
@@ -49534,6 +49662,7 @@ var init_dist3 = __esm({
|
|
|
49534
49662
|
init_logger();
|
|
49535
49663
|
init_changelog();
|
|
49536
49664
|
init_sketch_constraint_persist();
|
|
49665
|
+
init_pcb_layers();
|
|
49537
49666
|
}
|
|
49538
49667
|
});
|
|
49539
49668
|
|
|
@@ -54546,21 +54675,15 @@ var init_registry_dispatch = __esm({
|
|
|
54546
54675
|
});
|
|
54547
54676
|
|
|
54548
54677
|
// src/tools/pcb-layers.ts
|
|
54549
|
-
var PCB_LAYERS;
|
|
54550
|
-
var
|
|
54678
|
+
var INNER_COPPER, PCB_LAYERS, COPPER_STACK;
|
|
54679
|
+
var init_pcb_layers2 = __esm({
|
|
54551
54680
|
"src/tools/pcb-layers.ts"() {
|
|
54552
54681
|
"use strict";
|
|
54682
|
+
INNER_COPPER = Array.from({ length: 30 }, (_, i) => `In${i + 1}Cu`);
|
|
54553
54683
|
PCB_LAYERS = [
|
|
54554
54684
|
"FCu",
|
|
54555
54685
|
"BCu",
|
|
54556
|
-
|
|
54557
|
-
"In2Cu",
|
|
54558
|
-
"In3Cu",
|
|
54559
|
-
"In4Cu",
|
|
54560
|
-
"In5Cu",
|
|
54561
|
-
"In6Cu",
|
|
54562
|
-
"In7Cu",
|
|
54563
|
-
"In8Cu",
|
|
54686
|
+
...INNER_COPPER,
|
|
54564
54687
|
"FSilkS",
|
|
54565
54688
|
"BSilkS",
|
|
54566
54689
|
"FMask",
|
|
@@ -54575,6 +54698,7 @@ var init_pcb_layers = __esm({
|
|
|
54575
54698
|
"UserDrawings",
|
|
54576
54699
|
"UserComments"
|
|
54577
54700
|
];
|
|
54701
|
+
COPPER_STACK = ["FCu", ...INNER_COPPER, "BCu"];
|
|
54578
54702
|
}
|
|
54579
54703
|
});
|
|
54580
54704
|
|
|
@@ -54683,7 +54807,7 @@ var VALID_LAYERS;
|
|
|
54683
54807
|
var init_pcb_validate = __esm({
|
|
54684
54808
|
"src/tools/pcb-validate.ts"() {
|
|
54685
54809
|
"use strict";
|
|
54686
|
-
|
|
54810
|
+
init_pcb_layers2();
|
|
54687
54811
|
VALID_LAYERS = new Set(PCB_LAYERS);
|
|
54688
54812
|
}
|
|
54689
54813
|
});
|
|
@@ -62143,7 +62267,7 @@ function ecadUnverifiable(check2, outcome) {
|
|
|
62143
62267
|
isError: true
|
|
62144
62268
|
};
|
|
62145
62269
|
}
|
|
62146
|
-
function
|
|
62270
|
+
function isCopperLayer2(layer) {
|
|
62147
62271
|
return COPPER_LAYER_SET.has(layer);
|
|
62148
62272
|
}
|
|
62149
62273
|
function suggestLayer(name) {
|
|
@@ -62168,7 +62292,7 @@ function validateLayer(raw) {
|
|
|
62168
62292
|
function validateCopperLayer(raw) {
|
|
62169
62293
|
const res = validateLayer(raw);
|
|
62170
62294
|
if ("error" in res) return res;
|
|
62171
|
-
if (!
|
|
62295
|
+
if (!isCopperLayer2(res.layer)) {
|
|
62172
62296
|
return {
|
|
62173
62297
|
error: `layer '${res.layer}' is not a copper layer; copper layers: ${COPPER_LAYERS.join(", ")}`
|
|
62174
62298
|
};
|
|
@@ -66384,7 +66508,7 @@ function searchFootprints(args) {
|
|
|
66384
66508
|
};
|
|
66385
66509
|
}
|
|
66386
66510
|
function padCopperLayers(pad) {
|
|
66387
|
-
return pad.layers.filter((l) =>
|
|
66511
|
+
return pad.layers.filter((l) => isCopperLayer2(l));
|
|
66388
66512
|
}
|
|
66389
66513
|
function getPadPositions(args) {
|
|
66390
66514
|
const ctx = resolveDocInput(args);
|
|
@@ -66929,7 +67053,7 @@ async function setStackup(args) {
|
|
|
66929
67053
|
if (copperOz != null) {
|
|
66930
67054
|
const t2 = round33(copperOz * OZ_TO_MM);
|
|
66931
67055
|
for (const l of stackup) {
|
|
66932
|
-
if (
|
|
67056
|
+
if (isCopperLayer2(l.layer)) l.copperThickness = t2;
|
|
66933
67057
|
}
|
|
66934
67058
|
}
|
|
66935
67059
|
for (const ov of perLayer ?? []) {
|
|
@@ -66941,7 +67065,7 @@ async function setStackup(args) {
|
|
|
66941
67065
|
const layerName = layerRes.layer;
|
|
66942
67066
|
let entry = stackup.find((l) => l.layer === layerName);
|
|
66943
67067
|
if (!entry) {
|
|
66944
|
-
if (!
|
|
67068
|
+
if (!isCopperLayer2(layerName)) {
|
|
66945
67069
|
return fail2(`cannot create non-copper layer "${layerName}" \u2014 only copper layers are auto-added`);
|
|
66946
67070
|
}
|
|
66947
67071
|
entry = { layer: layerName };
|
|
@@ -70321,22 +70445,13 @@ var init_ecad2 = __esm({
|
|
|
70321
70445
|
init_em_claims();
|
|
70322
70446
|
init_enclosure();
|
|
70323
70447
|
init_pcb_validate();
|
|
70324
|
-
|
|
70448
|
+
init_pcb_layers2();
|
|
70325
70449
|
init_ecad_diff();
|
|
70326
70450
|
init_artifact_store();
|
|
70327
70451
|
init_remote();
|
|
70328
70452
|
init_tool_def();
|
|
70329
70453
|
PCB_LAYER_SET = new Set(PCB_LAYERS);
|
|
70330
|
-
COPPER_LAYERS =
|
|
70331
|
-
"FCu",
|
|
70332
|
-
"BCu",
|
|
70333
|
-
"In1Cu",
|
|
70334
|
-
"In2Cu",
|
|
70335
|
-
"In3Cu",
|
|
70336
|
-
"In4Cu",
|
|
70337
|
-
"In5Cu",
|
|
70338
|
-
"In6Cu"
|
|
70339
|
-
];
|
|
70454
|
+
COPPER_LAYERS = COPPER_STACK;
|
|
70340
70455
|
COPPER_LAYER_SET = new Set(COPPER_LAYERS);
|
|
70341
70456
|
POSITION_TOLERANCE = 0.01;
|
|
70342
70457
|
PIN_SEP = String.fromCharCode(0);
|
|
@@ -73774,9 +73889,7 @@ async function renderStackup(args) {
|
|
|
73774
73889
|
isError: true
|
|
73775
73890
|
};
|
|
73776
73891
|
}
|
|
73777
|
-
const
|
|
73778
|
-
const present = COPPER_LAYERS2.filter((l) => declared.has(l));
|
|
73779
|
-
const copper = present.length > 0 ? [...present] : ["FCu", "BCu"];
|
|
73892
|
+
const copper = boardCopperLayers(pcb);
|
|
73780
73893
|
const pcbJson = JSON.stringify(pcb);
|
|
73781
73894
|
const content = [];
|
|
73782
73895
|
const index = [];
|
|
@@ -73843,7 +73956,7 @@ async function renderStackup(args) {
|
|
|
73843
73956
|
});
|
|
73844
73957
|
return withRenderAssets({ content }, assets);
|
|
73845
73958
|
}
|
|
73846
|
-
var renderViewSchema, SVG_SCALE, DEFAULT_WIDTH_PX, MAX_NODES, MAX_PATTERN_INSTANCES, MAX_RENDER_TRIANGLES, MAX_RASTER_SVG_BYTES, MAX_INLINE_SVG_BYTES, renderPcbSchema, PCB_MARGIN_MM, RATSNEST_COLOR, renderRatsnestSchema,
|
|
73959
|
+
var renderViewSchema, SVG_SCALE, DEFAULT_WIDTH_PX, MAX_NODES, MAX_PATTERN_INSTANCES, MAX_RENDER_TRIANGLES, MAX_RASTER_SVG_BYTES, MAX_INLINE_SVG_BYTES, renderPcbSchema, PCB_MARGIN_MM, RATSNEST_COLOR, renderRatsnestSchema, renderStackupSchema, toolDefs24;
|
|
73847
73960
|
var init_render2 = __esm({
|
|
73848
73961
|
"src/tools/render.ts"() {
|
|
73849
73962
|
"use strict";
|
|
@@ -73992,16 +74105,6 @@ var init_render2 = __esm({
|
|
|
73992
74105
|
},
|
|
73993
74106
|
required: ["document_id"]
|
|
73994
74107
|
};
|
|
73995
|
-
COPPER_LAYERS2 = [
|
|
73996
|
-
"FCu",
|
|
73997
|
-
"In1Cu",
|
|
73998
|
-
"In2Cu",
|
|
73999
|
-
"In3Cu",
|
|
74000
|
-
"In4Cu",
|
|
74001
|
-
"In5Cu",
|
|
74002
|
-
"In6Cu",
|
|
74003
|
-
"BCu"
|
|
74004
|
-
];
|
|
74005
74108
|
renderStackupSchema = {
|
|
74006
74109
|
type: "object",
|
|
74007
74110
|
properties: {
|
|
@@ -84592,8 +84695,8 @@ var init_server3 = __esm({
|
|
|
84592
84695
|
init_order_feed();
|
|
84593
84696
|
init_animate();
|
|
84594
84697
|
PKG_VERSION = (() => {
|
|
84595
|
-
if ("0.10.0-main.
|
|
84596
|
-
return "0.10.0-main.
|
|
84698
|
+
if ("0.10.0-main.95") {
|
|
84699
|
+
return "0.10.0-main.95";
|
|
84597
84700
|
}
|
|
84598
84701
|
try {
|
|
84599
84702
|
const req = createRequire2(import.meta.url);
|
|
@@ -84602,8 +84705,8 @@ var init_server3 = __esm({
|
|
|
84602
84705
|
return "0.0.0";
|
|
84603
84706
|
}
|
|
84604
84707
|
})();
|
|
84605
|
-
BUILD_SHA = "
|
|
84606
|
-
BUILD_TIME = "2026-10-
|
|
84708
|
+
BUILD_SHA = "2182e0fa666586bfac3ebff40ad17af91836bf97";
|
|
84709
|
+
BUILD_TIME = "2026-10-17T19:27:56.972Z";
|
|
84607
84710
|
SHORT_SHA = BUILD_SHA === "unknown" ? "unknown" : BUILD_SHA.slice(0, 7);
|
|
84608
84711
|
VERSION_WITH_BUILD = SHORT_SHA === "unknown" ? PKG_VERSION : `${PKG_VERSION}+${SHORT_SHA}`;
|
|
84609
84712
|
INSTANCE_ID = randomUUID7().slice(0, 8);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vcad/mcp",
|
|
3
|
-
"version": "0.10.0-main.
|
|
3
|
+
"version": "0.10.0-main.95",
|
|
4
4
|
"description": "vcad MCP server — parametric CAD + PCB design tools for AI agents (self-contained: bundled server + kernel WASM)",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
},
|
|
20
20
|
"homepage": "https://vcad.io",
|
|
21
21
|
"vcadBuild": {
|
|
22
|
-
"sha": "
|
|
23
|
-
"builtAt": "2026-10-
|
|
22
|
+
"sha": "2182e0fa666586bfac3ebff40ad17af91836bf97",
|
|
23
|
+
"builtAt": "2026-10-17T19:27:56.972Z"
|
|
24
24
|
}
|
|
25
25
|
}
|
package/vcad_kernel_wasm_bg.wasm
CHANGED
|
Binary file
|