Skip to content

Commit

Permalink
Deploying to gh-pages from @ 55f0dd0 🚀
Browse files Browse the repository at this point in the history
  • Loading branch information
leomcelroy committed Apr 12, 2024
1 parent 81b28ff commit 26dfaaa
Show file tree
Hide file tree
Showing 78 changed files with 2,668 additions and 2,341 deletions.
1,395 changes: 0 additions & 1,395 deletions assets/index-1e22db5a.js

This file was deleted.

1 change: 1 addition & 0 deletions assets/index-4fc4889f.css

Large diffs are not rendered by default.

1,760 changes: 1,760 additions & 0 deletions assets/index-502f3513.js

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion assets/index-e1b340c7.css

This file was deleted.

32 changes: 16 additions & 16 deletions examples/USB-FT230XS-UPDI.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,25 +30,25 @@ let board = new PCB();


/* -- ADD_COMPONENTS -- */
let IC1 = board.add(FT230XS, {translate: pt(x+width/2.0, y+.7), label: 'IC1\nFT230XS'});
let C1 = board.add(C_1206, {translate: pt(IC1.padX("CB3")+.1, IC1.posY), rotate: 90, label: 'C1\n1uF'});
let J1 = board.add(USB_A_plug, {translate: pt(IC1.posX, y+.29), rotate: -90, label: 'J1 USB\n'});
let R1 = board.add(R_1206, {translate: pt(IC1.posX+.05, IC1.posY-.22), rotate: 90, label: 'R1\n49'});
let R2 = board.add(R_1206, {translate: pt(IC1.posX-.05, R1.posY), rotate: 90, label: 'R2\n49'});
let C2 = board.add(C_1206, {translate: pt(J1.padX("5V")+.065, R1.posY), label: 'C2\n10pF'});
let C3 = board.add(C_1206, {translate: pt(J1.padX("GND")-.065, R1.posY), label: 'C3\n10pF'});
let J2 = board.add(header_UPDI_reverse, {translate: pt(IC1.posX, y+height-.23), rotate: -90, label: 'J2\nUPDI'});
let R3 = board.add(R_1206, {translate: pt(IC1.padX("TXD")-.1, IC1.padY("TXD")+.05), rotate: 90, label: 'R3\n4.99k'});

let interior = geo.path(path([x, y+height],
let IC1 = board.add(FT230XS, {translate: pt(x+width/2.0, y+.7), id: 'IC1\nFT230XS'});
let C1 = board.add(C_1206, {translate: pt(IC1.padX("CB3")+.1, IC1.posY), rotate: 90, id: 'C1\n1uF'});
let J1 = board.add(USB_A_plug, {translate: pt(IC1.posX, y+.29), rotate: -90, id: 'J1 USB\n'});
let R1 = board.add(R_1206, {translate: pt(IC1.posX+.05, IC1.posY-.22), rotate: 90, id: 'R1\n49'});
let R2 = board.add(R_1206, {translate: pt(IC1.posX-.05, R1.posY), rotate: 90, id: 'R2\n49'});
let C2 = board.add(C_1206, {translate: pt(J1.padX("5V")+.065, R1.posY), id: 'C2\n10pF'});
let C3 = board.add(C_1206, {translate: pt(J1.padX("GND")-.065, R1.posY), id: 'C3\n10pF'});
let J2 = board.add(header_UPDI_reverse, {translate: pt(IC1.posX, y+height-.23), rotate: -90, id: 'J2\nUPDI'});
let R3 = board.add(R_1206, {translate: pt(IC1.padX("TXD")-.1, IC1.padY("TXD")+.05), rotate: 90, id: 'R3\n4.99k'});

let outline = geo.path(path([x, y+height],
[x+width, y+height],
[x+width, y],
[x, y]));

geo.difference(interior, geo.rotate(geo.translate(geo.rectangle(1.05, 9.76), [0.475+J1.posX, 5.12+J1.posY]), -90.00000001, J1.pos));
geo.difference(interior, geo.rotate(geo.translate(geo.rectangle(1.05, 9.76), [0.475+J1.posX, -5.12+J1.posY]), -90.00000001, J1.pos));
geo.difference(outline, geo.rotate(geo.translate(geo.rectangle(1.05, 9.76), [0.475+J1.posX, 5.12+J1.posY]), -90.00000001, J1.pos));
geo.difference(outline, geo.rotate(geo.translate(geo.rectangle(1.05, 9.76), [0.475+J1.posX, -5.12+J1.posY]), -90.00000001, J1.pos));

board.addShape("interior", interior);
board.addShape("outline", outline);


/* -- ADD_WIRES -- */
Expand Down Expand Up @@ -174,7 +174,7 @@ board.wire(path([C3.posX, IC1.padY("GND1")-.003],
renderPCB({
pcb: board,
layerColors: {
"interior": "#002d00ff",
"outline": "#002d00ff",
"B.Cu": "#ff4c007f",
"F.Cu": "#be7a27cc",
"B.Mask": "#ff814bff",
Expand All @@ -186,5 +186,5 @@ renderPCB({
x: [x-border, x+width+border],
y: [y-border, y+height+border]
},
mm_per_unit: 25.4
mmPerUnit: 25.4
})
30 changes: 15 additions & 15 deletions examples/USB-FT230XS-serial.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,24 +30,24 @@ let board = new PCB();


/* -- ADD_COMPONENTS -- */
let IC1 = board.add(FT230XS, {translate: pt(x+width/2.0, y+.7), label: 'IC1\nFT230XS'});
let C1 = board.add(C_1206, {translate: pt(IC1.padX("CB3")+.1, IC1.posY), rotate: 90, label: 'C1\n1uF'});
let J1 = board.add(USB_A_plug, {translate: pt(IC1.posX, y+.29), rotate: -90, label: 'J1 USB\n'});
let R1 = board.add(R_1206, {translate: pt(IC1.posX+.05, IC1.posY-.22), rotate: 90, label: 'R1\n49'});
let R2 = board.add(R_1206, {translate: pt(IC1.posX-.05, R1.posY), rotate: 90, label: 'R2\n49'});
let C2 = board.add(C_1206, {translate: pt(J1.padX("5V")+.065, R1.posY), label: 'C2\n10pF'});
let C3 = board.add(C_1206, {translate: pt(J1.padX("GND")-.065, R1.posY), label: 'C3\n10pF'});
let J2 = board.add(header_serial_reverse, {translate: pt(IC1.posX, y+height-.23), rotate: 90, label: 'J2\nserial'});

let interior = geo.path(path([x, y+height],
let IC1 = board.add(FT230XS, {translate: pt(x+width/2.0, y+.7), id: 'IC1\nFT230XS'});
let C1 = board.add(C_1206, {translate: pt(IC1.padX("CB3")+.1, IC1.posY), rotate: 90, id: 'C1\n1uF'});
let J1 = board.add(USB_A_plug, {translate: pt(IC1.posX, y+.29), rotate: -90, id: 'J1 USB\n'});
let R1 = board.add(R_1206, {translate: pt(IC1.posX+.05, IC1.posY-.22), rotate: 90, id: 'R1\n49'});
let R2 = board.add(R_1206, {translate: pt(IC1.posX-.05, R1.posY), rotate: 90, id: 'R2\n49'});
let C2 = board.add(C_1206, {translate: pt(J1.padX("5V")+.065, R1.posY), id: 'C2\n10pF'});
let C3 = board.add(C_1206, {translate: pt(J1.padX("GND")-.065, R1.posY), id: 'C3\n10pF'});
let J2 = board.add(header_serial_reverse, {translate: pt(IC1.posX, y+height-.23), rotate: 90, id: 'J2\nserial'});

let outline = geo.path(path([x, y+height],
[x+width, y+height],
[x+width, y],
[x, y]));

geo.difference(interior, geo.rotate(geo.translate(geo.rectangle(1.05, 9.76), [0.475+J1.posX, 5.12+J1.posY]), -90.00000001, J1.pos));
geo.difference(interior, geo.rotate(geo.translate(geo.rectangle(1.05, 9.76), [0.475+J1.posX, -5.12+J1.posY]), -90.00000001, J1.pos));
geo.difference(outline, geo.rotate(geo.translate(geo.rectangle(1.05, 9.76), [0.475+J1.posX, 5.12+J1.posY]), -90.00000001, J1.pos));
geo.difference(outline, geo.rotate(geo.translate(geo.rectangle(1.05, 9.76), [0.475+J1.posX, -5.12+J1.posY]), -90.00000001, J1.pos));

board.addShape("interior", interior);
board.addShape("outline", outline);


/* -- ADD_WIRES -- */
Expand Down Expand Up @@ -178,7 +178,7 @@ board.wire(path(J2.pad("Rx"),
renderPCB({
pcb: board,
layerColors: {
"interior": "#002d00ff",
"outline": "#002d00ff",
"B.Cu": "#ff4c007f",
"F.Cu": "#be7a27cc",
"B.Mask": "#ff814bff",
Expand All @@ -190,5 +190,5 @@ renderPCB({
x: [x-border, x+width+border],
y: [y-border, y+height+border]
},
mm_per_unit: 25.4
mmPerUnit: 25.4
})
46 changes: 23 additions & 23 deletions examples/crown.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ if (do_holes) {
}
}

board.addShape("interior", crown);
board.addShape("outline", crown);

let copper = structuredClone(crown);

Expand All @@ -124,25 +124,25 @@ geo.difference(copper, middle_band);
board.addShape("F.Cu", copper);

/* -- ADD_COMPONENTS -- */
let R10 = board.add(R_1206, { translate: pt(-0.023, 0.521), rotate: -90, name: "R10" })
let LED4 = board.add(LED_1206, { translate: pt(-0.337, 0.218), rotate: 0, name: "LED4" })
let LED5 = board.add(LED_1206, { translate: pt(0.279, 0.224), rotate: 0, name: "LED5" })
let R7 = board.add(R_1206, { translate: pt(0.068, 0.523), rotate: -90, name: "R7" })
let R9 = board.add(R_1206, { translate: pt(0.154, 0.524), rotate: -90, name: "R9" })

let R8 = board.add(R_1206, { translate: pt(0.333, 0.723), rotate: 0, name: "R8" })
let PT = board.add(phototransistor_1206, { translate: pt(-0.396, 0.892), rotate: 180, name: "photo" })
let J2 = board.add(USB_A_plug, { translate: pt(0, 2.45), rotate: 90, name: "USB" })
let IC1 = board.add(SAMD21E, { translate: pt(-0.01, 0.879), rotate: 0, name: "D21E", padLabelSize: 0.0109 })
let J1 = board.add(header_SWD, {translate: pt(IC1.posX, IC1.padY("DIO")+.34), rotate: -90, name: 'J1 SWD'});
let C1 = board.add(C_1206, {translate: pt(IC1.padX("GND2"), IC1.padY("A27")+0.15), name: 'C1 1uF'});
let C2 = board.add(C_1206, {translate: pt(IC1.padX("A07")-0.015, IC1.padY("VAN")-0.116), rotate: 90, name: 'C2\n1uF'});
let IC2 = board.add(regulator_SOT23, {translate: pt(C2.posX-0.157, C2.posY), rotate: -90, name: 'IC2\n3.3V'});
let LED1 = board.add(LED_1206, { translate: pt(-3.252, 0.452), rotate: -90, name: "LED1" })
let LED2 = board.add(LED_1206, { translate: pt(0.257, 1.947), rotate: 90, name: "LED2" })
let R2 = board.add(R_1206, { translate: pt(0.337, 0.894), rotate: 0, name: "R2" })
let LED3 = board.add(LED_1206, { translate: pt(3.27, 0.44), rotate: 270, name: "LED3" })
let R5 = board.add(R_1206, { translate: pt(-0.339, 1.04), rotate: 270, name: "R5" })
let R10 = board.add(R_1206, { translate: pt(-0.023, 0.521), rotate: -90, id: "R10" })
let LED4 = board.add(LED_1206, { translate: pt(-0.337, 0.218), rotate: 0, id: "LED4" })
let LED5 = board.add(LED_1206, { translate: pt(0.279, 0.224), rotate: 0, id: "LED5" })
let R7 = board.add(R_1206, { translate: pt(0.068, 0.523), rotate: -90, id: "R7" })
let R9 = board.add(R_1206, { translate: pt(0.154, 0.524), rotate: -90, id: "R9" })

let R8 = board.add(R_1206, { translate: pt(0.333, 0.723), rotate: 0, id: "R8" })
let PT = board.add(phototransistor_1206, { translate: pt(-0.396, 0.892), rotate: 180, id: "photo" })
let J2 = board.add(USB_A_plug, { translate: pt(0, 2.45), rotate: 90, id: "USB" })
let IC1 = board.add(SAMD21E, { translate: pt(-0.01, 0.879), rotate: 0, id: "D21E", padLabelSize: 0.0109 })
let J1 = board.add(header_SWD, {translate: pt(IC1.posX, IC1.padY("DIO")+.34), rotate: -90, id: 'J1 SWD'});
let C1 = board.add(C_1206, {translate: pt(IC1.padX("GND2"), IC1.padY("A27")+0.15), id: 'C1 1uF'});
let C2 = board.add(C_1206, {translate: pt(IC1.padX("A07")-0.015, IC1.padY("VAN")-0.116), rotate: 90, id: 'C2\n1uF'});
let IC2 = board.add(regulator_SOT23, {translate: pt(C2.posX-0.157, C2.posY), rotate: -90, id: 'IC2\n3.3V'});
let LED1 = board.add(LED_1206, { translate: pt(-3.252, 0.452), rotate: -90, id: "LED1" })
let LED2 = board.add(LED_1206, { translate: pt(0.257, 1.947), rotate: 90, id: "LED2" })
let R2 = board.add(R_1206, { translate: pt(0.337, 0.894), rotate: 0, id: "R2" })
let LED3 = board.add(LED_1206, { translate: pt(3.27, 0.44), rotate: 270, id: "LED3" })
let R5 = board.add(R_1206, { translate: pt(-0.339, 1.04), rotate: 270, id: "R5" })



Expand All @@ -155,7 +155,7 @@ let USB_rect = geo.path([[-w_USB/2, -0.2],

geo.translate(USB_rect, J2.pos);

board.addShape("interior", USB_rect);
board.addShape("outline", USB_rect);

/* -- ADD_WIRES -- */
board.wire(path(
Expand Down Expand Up @@ -454,7 +454,7 @@ renderPCB({

//"F.Cu": "#ffffffff",

"interior": "#002d00ff",
"outline": "#002d00ff",
"B.Cu": "#ff4c007f",
"F.Cu": "#ff8c00cc",
"drill": "#ffffffff",
Expand All @@ -465,5 +465,5 @@ renderPCB({
x: [-width/2, width/2],
y: [-lip, height]
},
mm_per_unit: 25.4
mmPerUnit: 25.4
});
Loading

0 comments on commit 26dfaaa

Please sign in to comment.