circuit-json-to-tscircuit 0.0.5 → 0.0.7
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/dist/{chunk-27MYDU45.js → chunk-VMXWQPSP.js} +12 -24
- package/dist/cli/main.js +7 -3
- package/dist/lib/index.js +1 -1
- package/lib/get-component-using-template.ts +11 -32
- package/package.json +6 -2
- package/tests/cli/cli-circuit-json-to-tsx.test.tsx +11 -19
- package/tests/test1-basic-circuit.test.tsx +18 -28
- package/tests/test2-get-component-template.test.tsx +39 -53
- package/tests/test3-kicad-mod-circuit-json-example.test.tsx +72 -81
|
@@ -5709,34 +5709,22 @@ var getComponentUsingTemplate = ({
|
|
|
5709
5709
|
}) => {
|
|
5710
5710
|
const footprintTsx = generateFootprintTsx(circuitJson);
|
|
5711
5711
|
return `
|
|
5712
|
-
import {
|
|
5713
|
-
|
|
5714
|
-
|
|
5715
|
-
|
|
5716
|
-
|
|
5717
|
-
|
|
5718
|
-
|
|
5719
|
-
}
|
|
5720
|
-
|
|
5721
|
-
export const ${componentName} = (props: Props) => {
|
|
5722
|
-
return (
|
|
5723
|
-
<chip
|
|
5724
|
-
{...props}
|
|
5725
|
-
${objUrl ? `cadModel={{
|
|
5712
|
+
import { type ChipProps } from "tscircuit"
|
|
5713
|
+
${pinLabels ? `const pinLabels = ${JSON.stringify(pinLabels, null, " ")} as const
|
|
5714
|
+
` : ""}export const ${componentName} = (props: ChipProps${pinLabels ? `<typeof pinLabels>` : ""}) => (
|
|
5715
|
+
<chip
|
|
5716
|
+
footprint={${footprintTsx}}
|
|
5717
|
+
${pinLabels ? "pinLabels={pinLabels}" : ""}
|
|
5718
|
+
${objUrl ? `cadModel={{
|
|
5726
5719
|
objUrl: "${objUrl}",
|
|
5727
5720
|
rotationOffset: { x: 0, y: 0, z: 0 },
|
|
5728
5721
|
positionOffset: { x: 0, y: 0, z: 0 },
|
|
5729
5722
|
}}` : ""}
|
|
5730
|
-
|
|
5731
|
-
|
|
5732
|
-
|
|
5733
|
-
|
|
5734
|
-
|
|
5735
|
-
)
|
|
5736
|
-
}
|
|
5737
|
-
|
|
5738
|
-
export const use${componentName} = createUseComponent(${componentName}, pinLabels)
|
|
5739
|
-
|
|
5723
|
+
${supplierPartNumbers ? `supplierPartNumbers={${JSON.stringify(supplierPartNumbers, null, " ")}}` : ""}
|
|
5724
|
+
${manufacturerPartNumber ? `manufacturerPartNumber="${manufacturerPartNumber}"` : ""}
|
|
5725
|
+
{...props}
|
|
5726
|
+
/>
|
|
5727
|
+
)
|
|
5740
5728
|
`.replace(/\n\s*\n/g, "\n").trim();
|
|
5741
5729
|
};
|
|
5742
5730
|
|
package/dist/cli/main.js
CHANGED
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
__require,
|
|
5
5
|
__toESM,
|
|
6
6
|
convertCircuitJsonToTscircuit
|
|
7
|
-
} from "../chunk-
|
|
7
|
+
} from "../chunk-VMXWQPSP.js";
|
|
8
8
|
|
|
9
9
|
// node_modules/commander/lib/error.js
|
|
10
10
|
var require_error = __commonJS({
|
|
@@ -3329,9 +3329,13 @@ import { readFile, writeFile } from "node:fs/promises";
|
|
|
3329
3329
|
// package.json
|
|
3330
3330
|
var package_default = {
|
|
3331
3331
|
name: "circuit-json-to-tscircuit",
|
|
3332
|
-
main: "dist/index.js",
|
|
3332
|
+
main: "dist/lib/index.js",
|
|
3333
|
+
exports: {
|
|
3334
|
+
".": "./dist/lib/index.js",
|
|
3335
|
+
"./cli": "./dist/cli/main.js"
|
|
3336
|
+
},
|
|
3333
3337
|
type: "module",
|
|
3334
|
-
version: "0.0.
|
|
3338
|
+
version: "0.0.6",
|
|
3335
3339
|
scripts: {
|
|
3336
3340
|
build: "tsup lib/index.ts cli/main.ts --format esm --dts",
|
|
3337
3341
|
test: "bun test",
|
package/dist/lib/index.js
CHANGED
|
@@ -20,38 +20,17 @@ export const getComponentUsingTemplate = ({
|
|
|
20
20
|
}: ComponentTemplateParams) => {
|
|
21
21
|
const footprintTsx = generateFootprintTsx(circuitJson)
|
|
22
22
|
return `
|
|
23
|
-
import {
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
<chip
|
|
35
|
-
{...props}
|
|
36
|
-
${
|
|
37
|
-
objUrl
|
|
38
|
-
? `cadModel={{
|
|
39
|
-
objUrl: "${objUrl}",
|
|
40
|
-
rotationOffset: { x: 0, y: 0, z: 0 },
|
|
41
|
-
positionOffset: { x: 0, y: 0, z: 0 },
|
|
42
|
-
}}`
|
|
43
|
-
: ""
|
|
44
|
-
}
|
|
45
|
-
${pinLabels ? `pinLabels={${JSON.stringify(pinLabels, null, " ")}}` : ""}
|
|
46
|
-
${supplierPartNumbers ? `supplierPartNumbers={${JSON.stringify(supplierPartNumbers, null, " ")}}` : ""}
|
|
47
|
-
${manufacturerPartNumber ? `manufacturerPartNumber="${manufacturerPartNumber}"` : ""}
|
|
48
|
-
footprint={${footprintTsx}}
|
|
49
|
-
/>
|
|
50
|
-
)
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
export const use${componentName} = createUseComponent(${componentName}, pinLabels)
|
|
54
|
-
|
|
23
|
+
import { type ChipProps } from "tscircuit"
|
|
24
|
+
${pinLabels ? `const pinLabels = ${JSON.stringify(pinLabels, null, " ")} as const\n` : ""}export const ${componentName} = (props: ChipProps${pinLabels ? `<typeof pinLabels>` : ""}) => (
|
|
25
|
+
<chip
|
|
26
|
+
footprint={${footprintTsx}}
|
|
27
|
+
${pinLabels ? "pinLabels={pinLabels}" : ""}
|
|
28
|
+
${objUrl ? `cadModel={{\n objUrl: \"${objUrl}\",\n rotationOffset: { x: 0, y: 0, z: 0 },\n positionOffset: { x: 0, y: 0, z: 0 },\n }}` : ""}
|
|
29
|
+
${supplierPartNumbers ? `supplierPartNumbers={${JSON.stringify(supplierPartNumbers, null, " ")}}` : ""}
|
|
30
|
+
${manufacturerPartNumber ? `manufacturerPartNumber=\"${manufacturerPartNumber}\"` : ""}
|
|
31
|
+
{...props}
|
|
32
|
+
/>
|
|
33
|
+
)
|
|
55
34
|
`
|
|
56
35
|
.replace(/\n\s*\n/g, "\n")
|
|
57
36
|
.trim()
|
package/package.json
CHANGED
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "circuit-json-to-tscircuit",
|
|
3
|
-
"main": "dist/index.js",
|
|
3
|
+
"main": "dist/lib/index.js",
|
|
4
|
+
"exports": {
|
|
5
|
+
".": "./dist/lib/index.js",
|
|
6
|
+
"./cli": "./dist/cli/main.js"
|
|
7
|
+
},
|
|
4
8
|
"type": "module",
|
|
5
|
-
"version": "0.0.
|
|
9
|
+
"version": "0.0.7",
|
|
6
10
|
"scripts": {
|
|
7
11
|
"build": "tsup lib/index.ts cli/main.ts --format esm --dts",
|
|
8
12
|
"test": "bun test",
|
|
@@ -18,25 +18,17 @@ test("should convert sample circuit.json to TSX", async () => {
|
|
|
18
18
|
// Verify output file content
|
|
19
19
|
const output = await readFile(outputPath, "utf-8")
|
|
20
20
|
expect(output).toMatchInlineSnapshot(`
|
|
21
|
-
"import {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
<smtpad portHints={["1","left"]} pcbX="-0.5mm" pcbY="0mm" width="0.6000000000000001mm" height="0.6000000000000001mm" shape="rect" />
|
|
33
|
-
<smtpad portHints={["2","right"]} pcbX="0.5mm" pcbY="0mm" width="0.6000000000000001mm" height="0.6000000000000001mm" shape="rect" />
|
|
34
|
-
</footprint>}
|
|
35
|
-
/>
|
|
36
|
-
)
|
|
37
|
-
}
|
|
38
|
-
export const useCircuit = createUseComponent(Circuit, pinLabels)"
|
|
39
|
-
`)
|
|
21
|
+
"import { type ChipProps } from "tscircuit"
|
|
22
|
+
export const Circuit = (props: ChipProps) => (
|
|
23
|
+
<chip
|
|
24
|
+
footprint={<footprint>
|
|
25
|
+
<smtpad portHints={["1","left"]} pcbX="-0.5mm" pcbY="0mm" width="0.6000000000000001mm" height="0.6000000000000001mm" shape="rect" />
|
|
26
|
+
<smtpad portHints={["2","right"]} pcbX="0.5mm" pcbY="0mm" width="0.6000000000000001mm" height="0.6000000000000001mm" shape="rect" />
|
|
27
|
+
</footprint>}
|
|
28
|
+
{...props}
|
|
29
|
+
/>
|
|
30
|
+
)"
|
|
31
|
+
`)
|
|
40
32
|
})
|
|
41
33
|
|
|
42
34
|
test("should require output path", async () => {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { test, expect } from "bun:test"
|
|
2
2
|
import { convertCircuitJsonToTscircuit } from "lib/index"
|
|
3
|
-
import {
|
|
3
|
+
import { readFile } from "node:fs/promises"
|
|
4
|
+
import { join } from "node:path"
|
|
4
5
|
|
|
5
6
|
declare module "bun:test" {
|
|
6
7
|
interface Matchers<T = unknown> {
|
|
@@ -9,38 +10,27 @@ declare module "bun:test" {
|
|
|
9
10
|
}
|
|
10
11
|
|
|
11
12
|
test("test1 basic circuit", async () => {
|
|
12
|
-
const
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
</group>,
|
|
13
|
+
const circuitJson = JSON.parse(
|
|
14
|
+
await readFile(
|
|
15
|
+
join(__dirname, "../assets/input-circuit-json.json"),
|
|
16
|
+
"utf-8",
|
|
17
|
+
),
|
|
18
18
|
)
|
|
19
19
|
|
|
20
|
-
const circuitJson = circuit.getCircuitJson()
|
|
21
|
-
|
|
22
20
|
const tscircuit = convertCircuitJsonToTscircuit(circuitJson, {
|
|
23
21
|
componentName: "MyResistor",
|
|
24
22
|
})
|
|
25
23
|
|
|
26
24
|
expect(tscircuit).toMatchInlineSnapshot(`
|
|
27
|
-
"import {
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
<smtpad portHints={["1","left"]} pcbX="-0.5mm" pcbY="0mm" width="0.6000000000000001mm" height="0.6000000000000001mm" shape="rect" />
|
|
39
|
-
<smtpad portHints={["2","right"]} pcbX="0.5mm" pcbY="0mm" width="0.6000000000000001mm" height="0.6000000000000001mm" shape="rect" />
|
|
40
|
-
</footprint>}
|
|
41
|
-
/>
|
|
42
|
-
)
|
|
43
|
-
}
|
|
44
|
-
export const useMyResistor = createUseComponent(MyResistor, pinLabels)"
|
|
45
|
-
`)
|
|
25
|
+
"import { type ChipProps } from "tscircuit"
|
|
26
|
+
export const MyResistor = (props: ChipProps) => (
|
|
27
|
+
<chip
|
|
28
|
+
footprint={<footprint>
|
|
29
|
+
<smtpad portHints={["1","left"]} pcbX="-0.5mm" pcbY="0mm" width="0.6000000000000001mm" height="0.6000000000000001mm" shape="rect" />
|
|
30
|
+
<smtpad portHints={["2","right"]} pcbX="0.5mm" pcbY="0mm" width="0.6000000000000001mm" height="0.6000000000000001mm" shape="rect" />
|
|
31
|
+
</footprint>}
|
|
32
|
+
{...props}
|
|
33
|
+
/>
|
|
34
|
+
)"
|
|
35
|
+
`)
|
|
46
36
|
})
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { test, expect } from "bun:test"
|
|
2
2
|
import { convertCircuitJsonToTscircuit } from "lib/index"
|
|
3
|
-
import {
|
|
3
|
+
import { readFile } from "node:fs/promises"
|
|
4
|
+
import { join } from "node:path"
|
|
4
5
|
import { getComponentUsingTemplate } from "lib/get-component-using-template"
|
|
5
6
|
|
|
6
7
|
test("test2 getComponentUsingTemplate", async () => {
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
</board>,
|
|
8
|
+
const circuitJson = JSON.parse(
|
|
9
|
+
await readFile(
|
|
10
|
+
join(__dirname, "../assets/input-circuit-json.json"),
|
|
11
|
+
"utf-8",
|
|
12
|
+
),
|
|
13
13
|
)
|
|
14
14
|
|
|
15
15
|
const tscircuitCode = getComponentUsingTemplate({
|
|
16
|
-
circuitJson
|
|
16
|
+
circuitJson,
|
|
17
17
|
componentName: "MyResistor",
|
|
18
18
|
pinLabels: {
|
|
19
19
|
pin1: ["pin1"],
|
|
@@ -25,49 +25,35 @@ test("test2 getComponentUsingTemplate", async () => {
|
|
|
25
25
|
})
|
|
26
26
|
|
|
27
27
|
expect(tscircuitCode).toMatchInlineSnapshot(`
|
|
28
|
-
"import {
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
"jlcpcb": [
|
|
60
|
-
"123456"
|
|
61
|
-
]
|
|
62
|
-
}}
|
|
63
|
-
manufacturerPartNumber="123456"
|
|
64
|
-
footprint={<footprint>
|
|
65
|
-
<smtpad portHints={["1","left"]} pcbX="-0.5mm" pcbY="0mm" width="0.6000000000000001mm" height="0.6000000000000001mm" shape="rect" />
|
|
66
|
-
<smtpad portHints={["2","right"]} pcbX="0.5mm" pcbY="0mm" width="0.6000000000000001mm" height="0.6000000000000001mm" shape="rect" />
|
|
67
|
-
</footprint>}
|
|
68
|
-
/>
|
|
69
|
-
)
|
|
70
|
-
}
|
|
71
|
-
export const useMyResistor = createUseComponent(MyResistor, pinLabels)"
|
|
72
|
-
`)
|
|
28
|
+
"import { type ChipProps } from "tscircuit"
|
|
29
|
+
const pinLabels = {
|
|
30
|
+
"pin1": [
|
|
31
|
+
"pin1"
|
|
32
|
+
],
|
|
33
|
+
"pin2": [
|
|
34
|
+
"pin2"
|
|
35
|
+
]
|
|
36
|
+
} as const
|
|
37
|
+
export const MyResistor = (props: ChipProps<typeof pinLabels>) => (
|
|
38
|
+
<chip
|
|
39
|
+
footprint={<footprint>
|
|
40
|
+
<smtpad portHints={["1","left"]} pcbX="-0.5mm" pcbY="0mm" width="0.6000000000000001mm" height="0.6000000000000001mm" shape="rect" />
|
|
41
|
+
<smtpad portHints={["2","right"]} pcbX="0.5mm" pcbY="0mm" width="0.6000000000000001mm" height="0.6000000000000001mm" shape="rect" />
|
|
42
|
+
</footprint>}
|
|
43
|
+
pinLabels={pinLabels}
|
|
44
|
+
cadModel={{
|
|
45
|
+
objUrl: "...",
|
|
46
|
+
rotationOffset: { x: 0, y: 0, z: 0 },
|
|
47
|
+
positionOffset: { x: 0, y: 0, z: 0 },
|
|
48
|
+
}}
|
|
49
|
+
supplierPartNumbers={{
|
|
50
|
+
"jlcpcb": [
|
|
51
|
+
"123456"
|
|
52
|
+
]
|
|
53
|
+
}}
|
|
54
|
+
manufacturerPartNumber="123456"
|
|
55
|
+
{...props}
|
|
56
|
+
/>
|
|
57
|
+
)"
|
|
58
|
+
`)
|
|
73
59
|
})
|
|
@@ -7,88 +7,79 @@ test("test3 kicad mod circuit json example", async () => {
|
|
|
7
7
|
})
|
|
8
8
|
|
|
9
9
|
expect(tscircuit).toMatchInlineSnapshot(`
|
|
10
|
-
"import {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
<
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
<platedhole portHints={["
|
|
23
|
-
<platedhole portHints={["
|
|
24
|
-
<platedhole portHints={["
|
|
25
|
-
<platedhole portHints={["
|
|
26
|
-
<platedhole portHints={["
|
|
27
|
-
<platedhole portHints={["
|
|
28
|
-
<platedhole portHints={["
|
|
29
|
-
<platedhole portHints={["
|
|
30
|
-
<platedhole portHints={["
|
|
31
|
-
<platedhole portHints={["
|
|
32
|
-
<platedhole portHints={["
|
|
33
|
-
<platedhole portHints={["
|
|
34
|
-
<platedhole portHints={["
|
|
35
|
-
<platedhole portHints={["
|
|
36
|
-
<platedhole portHints={["
|
|
37
|
-
<platedhole portHints={["
|
|
38
|
-
<platedhole portHints={["
|
|
39
|
-
<platedhole portHints={["
|
|
40
|
-
<platedhole portHints={["
|
|
41
|
-
<
|
|
42
|
-
<
|
|
43
|
-
<
|
|
44
|
-
<
|
|
45
|
-
<
|
|
46
|
-
<
|
|
47
|
-
<
|
|
48
|
-
<smtpad portHints={["
|
|
49
|
-
<smtpad portHints={["
|
|
50
|
-
<smtpad portHints={["
|
|
51
|
-
<smtpad portHints={["
|
|
52
|
-
<smtpad portHints={["
|
|
53
|
-
<smtpad portHints={["
|
|
54
|
-
<smtpad portHints={["
|
|
55
|
-
<smtpad portHints={["
|
|
56
|
-
<smtpad portHints={["
|
|
57
|
-
<smtpad portHints={["
|
|
58
|
-
<smtpad portHints={["
|
|
59
|
-
<smtpad portHints={["
|
|
60
|
-
<smtpad portHints={["
|
|
61
|
-
<smtpad portHints={["
|
|
62
|
-
<smtpad portHints={["
|
|
63
|
-
<smtpad portHints={["
|
|
64
|
-
<smtpad portHints={["
|
|
65
|
-
<smtpad portHints={["
|
|
66
|
-
<smtpad portHints={["
|
|
67
|
-
<smtpad portHints={["
|
|
68
|
-
<smtpad portHints={["
|
|
69
|
-
<
|
|
70
|
-
<
|
|
71
|
-
<
|
|
72
|
-
<
|
|
73
|
-
<
|
|
74
|
-
<
|
|
75
|
-
<
|
|
76
|
-
<silkscreenpath route={[{"x"
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
<silkscreenpath route={[{"x":6.985,"y":10.541},{"x":7.937499698293818,"y":10.285777964987211},{"x":8.63477796498721,"y":9.588499698293818},{"x":8.889999999999999,"y":8.636}]} />
|
|
83
|
-
<silkscreenpath route={[{"x":8.89,"y":-8.509},{"x":8.63477796498721,"y":-9.461499698293817},{"x":7.937499698293818,"y":-10.158777964987209},{"x":6.985,"y":-10.413999999999998}]} />
|
|
84
|
-
</footprint>}
|
|
85
|
-
/>
|
|
86
|
-
)
|
|
87
|
-
}
|
|
88
|
-
export const useTest3Component = createUseComponent(Test3Component, pinLabels)"
|
|
89
|
-
`)
|
|
10
|
+
"import { type ChipProps } from "tscircuit"
|
|
11
|
+
export const Test3Component = (props: ChipProps) => (
|
|
12
|
+
<chip
|
|
13
|
+
footprint={<footprint>
|
|
14
|
+
<platedhole portHints={["1"]} pcbX="-8.89mm" pcbY="7.62mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
15
|
+
<platedhole portHints={["2"]} pcbX="-8.89mm" pcbY="5.08mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
16
|
+
<platedhole portHints={["2"]} pcbX="-7.62mm" pcbY="5.08mm" outerDiameter="1.4mm" holeDiameter="0.85mm" shape="circle" />
|
|
17
|
+
<platedhole portHints={["3"]} pcbX="-8.89mm" pcbY="2.54mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
18
|
+
<platedhole portHints={["3"]} pcbX="-7.62mm" pcbY="2.54mm" outerDiameter="1.5mm" holeDiameter="0.85mm" shape="circle" />
|
|
19
|
+
<platedhole portHints={["4"]} pcbX="-8.89mm" pcbY="0mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
20
|
+
<platedhole portHints={["4"]} pcbX="-7.62mm" pcbY="0mm" outerDiameter="1.5mm" holeDiameter="0.85mm" shape="circle" />
|
|
21
|
+
<platedhole portHints={["5"]} pcbX="-8.89mm" pcbY="-2.54mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
22
|
+
<platedhole portHints={["5"]} pcbX="-7.62mm" pcbY="-2.54mm" outerDiameter="1.5mm" holeDiameter="0.85mm" shape="circle" />
|
|
23
|
+
<platedhole portHints={["6"]} pcbX="-8.89mm" pcbY="-5.08mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
24
|
+
<platedhole portHints={["6"]} pcbX="-7.62mm" pcbY="-5.08mm" outerDiameter="1.4mm" holeDiameter="0.85mm" shape="circle" />
|
|
25
|
+
<platedhole portHints={["7"]} pcbX="-8.89mm" pcbY="-7.62mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
26
|
+
<platedhole portHints={["7"]} pcbX="-7.62mm" pcbY="-7.62mm" outerDiameter="1.5mm" holeDiameter="0.85mm" shape="circle" />
|
|
27
|
+
<platedhole portHints={["8"]} pcbX="7.62mm" pcbY="-7.62mm" outerDiameter="1.524mm" holeDiameter="0.889mm" shape="circle" />
|
|
28
|
+
<platedhole portHints={["8"]} pcbX="8.89mm" pcbY="-7.62mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
29
|
+
<platedhole portHints={["9"]} pcbX="7.62mm" pcbY="-5.08mm" outerDiameter="1.4mm" holeDiameter="0.85mm" shape="circle" />
|
|
30
|
+
<platedhole portHints={["9"]} pcbX="8.89mm" pcbY="-5.08mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
31
|
+
<platedhole portHints={["10"]} pcbX="7.62mm" pcbY="-2.54mm" outerDiameter="1.5mm" holeDiameter="0.85mm" shape="circle" />
|
|
32
|
+
<platedhole portHints={["10"]} pcbX="8.89mm" pcbY="-2.54mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
33
|
+
<platedhole portHints={["11"]} pcbX="7.62mm" pcbY="0mm" outerDiameter="1.5mm" holeDiameter="0.85mm" shape="circle" />
|
|
34
|
+
<platedhole portHints={["11"]} pcbX="8.89mm" pcbY="0mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
35
|
+
<platedhole portHints={["12"]} pcbX="7.62mm" pcbY="2.54mm" outerDiameter="1.5mm" holeDiameter="0.85mm" shape="circle" />
|
|
36
|
+
<platedhole portHints={["12"]} pcbX="8.89mm" pcbY="2.54mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
37
|
+
<platedhole portHints={["13"]} pcbX="7.62mm" pcbY="5.08mm" outerDiameter="1.4mm" holeDiameter="0.85mm" shape="circle" />
|
|
38
|
+
<platedhole portHints={["13"]} pcbX="8.89mm" pcbY="5.08mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
39
|
+
<platedhole portHints={["14"]} pcbX="7.62mm" pcbY="7.62mm" outerDiameter="1.5mm" holeDiameter="0.85mm" shape="circle" />
|
|
40
|
+
<platedhole portHints={["14"]} pcbX="8.89mm" pcbY="7.62mm" outerDiameter="1.27mm" holeDiameter="0.7mm" shape="circle" />
|
|
41
|
+
<smtpad portHints={["1"]} pcbX="-8.278mm" pcbY="7.62mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
42
|
+
<smtpad portHints={["1"]} pcbX="-8.278mm" pcbY="7.62mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
43
|
+
<smtpad portHints={["2"]} pcbX="-8.337mm" pcbY="5.08mm" width="1.626mm" height="1.208mm" shape="rect" />
|
|
44
|
+
<smtpad portHints={["2"]} pcbX="-8.337mm" pcbY="5.08mm" width="1.626mm" height="1.208mm" shape="rect" />
|
|
45
|
+
<smtpad portHints={["3"]} pcbX="-8.278mm" pcbY="2.54mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
46
|
+
<smtpad portHints={["3"]} pcbX="-8.278mm" pcbY="2.54mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
47
|
+
<smtpad portHints={["4"]} pcbX="-8.278mm" pcbY="0mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
48
|
+
<smtpad portHints={["4"]} pcbX="-8.278mm" pcbY="0mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
49
|
+
<smtpad portHints={["5"]} pcbX="-8.278mm" pcbY="-2.54mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
50
|
+
<smtpad portHints={["5"]} pcbX="-8.278mm" pcbY="-2.54mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
51
|
+
<smtpad portHints={["6"]} pcbX="-8.337mm" pcbY="-5.08mm" width="1.626mm" height="1.208mm" shape="rect" />
|
|
52
|
+
<smtpad portHints={["6"]} pcbX="-8.337mm" pcbY="-5.08mm" width="1.626mm" height="1.208mm" shape="rect" />
|
|
53
|
+
<smtpad portHints={["7"]} pcbX="-8.278mm" pcbY="-7.62mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
54
|
+
<smtpad portHints={["7"]} pcbX="-8.278mm" pcbY="-7.62mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
55
|
+
<smtpad portHints={["8"]} pcbX="8.278mm" pcbY="-7.62mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
56
|
+
<smtpad portHints={["8"]} pcbX="8.278mm" pcbY="-7.62mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
57
|
+
<smtpad portHints={["9"]} pcbX="8.337mm" pcbY="-5.08mm" width="1.626mm" height="1.208mm" shape="rect" />
|
|
58
|
+
<smtpad portHints={["9"]} pcbX="8.337mm" pcbY="-5.08mm" width="1.626mm" height="1.208mm" shape="rect" />
|
|
59
|
+
<smtpad portHints={["10"]} pcbX="8.278mm" pcbY="-2.54mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
60
|
+
<smtpad portHints={["10"]} pcbX="8.278mm" pcbY="-2.54mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
61
|
+
<smtpad portHints={["11"]} pcbX="8.278mm" pcbY="0mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
62
|
+
<smtpad portHints={["11"]} pcbX="8.278mm" pcbY="0mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
63
|
+
<smtpad portHints={["12"]} pcbX="8.278mm" pcbY="2.54mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
64
|
+
<smtpad portHints={["12"]} pcbX="8.278mm" pcbY="2.54mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
65
|
+
<smtpad portHints={["13"]} pcbX="8.337mm" pcbY="5.08mm" width="1.626mm" height="1.208mm" shape="rect" />
|
|
66
|
+
<smtpad portHints={["13"]} pcbX="8.337mm" pcbY="5.08mm" width="1.626mm" height="1.208mm" shape="rect" />
|
|
67
|
+
<smtpad portHints={["14"]} pcbX="8.278mm" pcbY="7.62mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
68
|
+
<smtpad portHints={["14"]} pcbX="8.278mm" pcbY="7.62mm" width="1.626mm" height="1.325mm" shape="rect" />
|
|
69
|
+
<silkscreenpath route={[{"x":-8.89,"y":-8.509},{"x":-8.89,"y":8.636}]} />
|
|
70
|
+
<silkscreenpath route={[{"x":-6.985,"y":-10.414},{"x":6.985,"y":-10.414}]} />
|
|
71
|
+
<silkscreenpath route={[{"x":6.985,"y":10.541},{"x":-6.985,"y":10.541}]} />
|
|
72
|
+
<silkscreenpath route={[{"x":8.89,"y":-8.509},{"x":8.89,"y":8.636}]} />
|
|
73
|
+
<silkscreenpath route={[{"x":-8.89,"y":8.636},{"x":-8.634777964987212,"y":9.588499698293818},{"x":-7.937499698293819,"y":10.285777964987211},{"x":-6.985,"y":10.541}]} />
|
|
74
|
+
<silkscreenpath route={[{"x":-6.985,"y":-10.414},{"x":-7.937499698293818,"y":-10.158777964987209},{"x":-8.63477796498721,"y":-9.461499698293817},{"x":-8.89,"y":-8.509}]} />
|
|
75
|
+
<silkscreenpath route={[{"x":6.985,"y":10.541},{"x":7.937499698293818,"y":10.285777964987211},{"x":8.63477796498721,"y":9.588499698293818},{"x":8.889999999999999,"y":8.636}]} />
|
|
76
|
+
<silkscreenpath route={[{"x":8.89,"y":-8.509},{"x":8.63477796498721,"y":-9.461499698293817},{"x":7.937499698293818,"y":-10.158777964987209},{"x":6.985,"y":-10.413999999999998}]} />
|
|
77
|
+
</footprint>}
|
|
78
|
+
{...props}
|
|
79
|
+
/>
|
|
80
|
+
)"
|
|
81
|
+
`)
|
|
90
82
|
})
|
|
91
|
-
|
|
92
83
|
const circuitJson: any = [
|
|
93
84
|
{
|
|
94
85
|
type: "source_component",
|