@tscircuit/footprinter 0.0.269 → 0.0.271
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/index.js +12 -9
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -132,7 +132,7 @@ var platedhole = (pn, x, y, id, od) => {
|
|
|
132
132
|
|
|
133
133
|
// src/helpers/platedHoleWithRectPad.ts
|
|
134
134
|
import { mm as mm2 } from "@tscircuit/mm";
|
|
135
|
-
var platedHoleWithRectPad = (pn, x, y, holeDiameter, rectPadWidth, rectPadHeight) => {
|
|
135
|
+
var platedHoleWithRectPad = (pn, x, y, holeDiameter, rectPadWidth, rectPadHeight, holeOffsetX, holeOffsetY) => {
|
|
136
136
|
return {
|
|
137
137
|
pcb_plated_hole_id: "",
|
|
138
138
|
type: "pcb_plated_hole",
|
|
@@ -146,7 +146,9 @@ var platedHoleWithRectPad = (pn, x, y, holeDiameter, rectPadWidth, rectPadHeight
|
|
|
146
146
|
rect_pad_height: mm2(rectPadHeight),
|
|
147
147
|
pcb_port_id: "",
|
|
148
148
|
layers: ["top", "bottom"],
|
|
149
|
-
port_hints: [pn.toString()]
|
|
149
|
+
port_hints: [pn.toString()],
|
|
150
|
+
hole_offset_x: holeOffsetX,
|
|
151
|
+
hole_offset_y: holeOffsetY
|
|
150
152
|
};
|
|
151
153
|
};
|
|
152
154
|
|
|
@@ -1465,8 +1467,8 @@ var sot23_def = base_def.extend({
|
|
|
1465
1467
|
num_pins: z11.number().default(3),
|
|
1466
1468
|
w: z11.string().default("1.92mm"),
|
|
1467
1469
|
h: z11.string().default("2.74mm"),
|
|
1468
|
-
pl: z11.string().default("
|
|
1469
|
-
pw: z11.string().default("0.
|
|
1470
|
+
pl: z11.string().default("1.32mm"),
|
|
1471
|
+
pw: z11.string().default("0.6mm"),
|
|
1470
1472
|
p: z11.string().default("0.95mm"),
|
|
1471
1473
|
string: z11.string().optional()
|
|
1472
1474
|
});
|
|
@@ -1507,14 +1509,14 @@ var sot23 = (raw_params) => {
|
|
|
1507
1509
|
throw new Error("Invalid number of pins");
|
|
1508
1510
|
};
|
|
1509
1511
|
var getCcwSot23Coords = (parameters) => {
|
|
1510
|
-
const { pn, w, h, pl } = parameters;
|
|
1512
|
+
const { pn, w, h, pl, p } = parameters;
|
|
1511
1513
|
if (pn === 1) {
|
|
1512
|
-
return { x: -1.
|
|
1514
|
+
return { x: -1.155, y: p };
|
|
1513
1515
|
}
|
|
1514
1516
|
if (pn === 2) {
|
|
1515
|
-
return { x: 1.
|
|
1517
|
+
return { x: -1.155, y: -p };
|
|
1516
1518
|
}
|
|
1517
|
-
return { x: 1.
|
|
1519
|
+
return { x: 1.15, y: 0 };
|
|
1518
1520
|
};
|
|
1519
1521
|
var sot23_3 = (parameters) => {
|
|
1520
1522
|
const pads = [];
|
|
@@ -1524,7 +1526,8 @@ var sot23_3 = (parameters) => {
|
|
|
1524
1526
|
pn: i + 1,
|
|
1525
1527
|
w: Number.parseFloat(parameters.w),
|
|
1526
1528
|
h: Number.parseFloat(parameters.h),
|
|
1527
|
-
pl: Number.parseFloat(parameters.pl)
|
|
1529
|
+
pl: Number.parseFloat(parameters.pl),
|
|
1530
|
+
p: Number.parseFloat(parameters.p)
|
|
1528
1531
|
});
|
|
1529
1532
|
pads.push(
|
|
1530
1533
|
rectpad(
|