Root/modules/c-smd.fpd

Source at commit d37268a6ba7dd08f54960a03ca755dc943e3636c created 7 years 1 month ago.
By Werner Almesberger, modules/: add PAD_S_120x120; correct classification of PAD_S_150x150
1/* MACHINE-GENERATED ! */
2
3frame pad {
4    __0: vec @(b/2, a/2)
5    __1: vec @(-b/2, -a/2)
6    pad "$pin" . __0
7}
8
9frame pads {
10    table
11        { pin, dx, dy }
12        { 1, -1, -1 }
13        { 2, 1, -1 }
14
15    __0: vec @(dx*Gx/2, 0mm)
16    frame pad .
17}
18
19frame outline_B {
20    __0: vec @(-(B1/2-0.17*B1+w), A1/2+w)
21    __1: vec @(-(B1/2-0.17*B1+w), -(A1/2+w))
22    __2: vec @(B1/2+w, A1/2+w)
23    line __0 . w
24    __4: vec .(0mm, -(A1-a)/2)
25    line __2 . w
26    __3: vec @(B1/2+w, -(A1/2+w))
27    line __1 . w
28    __5: vec .(0mm, (A1-a)/2)
29    line __3 . w
30}
31
32frame outline_slope {
33    table
34        { px, py, x, y }
35        { -(B1/2+w-0.085*B1), A1/2-0.085*A1, 0.17*B1, 0.17*A1+2*w }
36        { -(B1/2+w-0.085*B1), -(A1/2-0.085*A1), 0.17*B1, -(0.17*A1+2*w) }
37
38    __0: vec @(px, py)
39    __1: vec .(-x/2, -y/2)
40    __2: vec __0(x/2, y/2)
41    line . __1 w
42}
43
44frame outline {
45    table
46        { px, py, x, y }
47        { -(B1+2*w)/2, 0.17*A1+3*w, 0mm, 0.15*A1 }
48        { -(B1+2*w)/2, -0.17*A1-3*w, 0mm, 0.15*A1 }
49
50    __0: vec @(px, py)
51    __1: vec .(x/2, y/2)
52    __2: vec __0(-x/2, -y/2)
53    line . __1 w
54}
55
56package "c-smd-${D}x${L}"
57unit mm
58
59table
60    { D, L, Gx, A1, B1, a, b, c, d }
61    { 5mm, 6.1mm, b+c, 5.3mm, 5.3mm, 1.6mm, 3mm, 1.4mm, 2*b+c }
62    { 6.3mm, 8mm, b+c, 6.6mm, 6.6mm, 1.6mm, 3.5mm, 2.1mm, 2*b+c }
63    { 8mm, 10.5mm, b+c, 8.3mm, 8.3mm, 2.2mm, 4.1mm, 3mm, 2*b+c }
64    { 10mm, 10.5mm, b+c, 10.3mm, 10.3mm, 2.2mm, 4.3mm, 4.5mm, 2*b+c }
65
66set w = 5mil
67
68frame pads @
69frame outline @
70frame outline_slope @
71frame outline_B @
72measy pad.__1 -> pad.__0 0.5mm
73measx pad.__1 -> pad.__0 -1mm
74measx pad.__0 >> pad.__1 1mm
75measx outline.__2 >> outline.__1 -1mm
76meas pads.__0 >> pads.__0 2.5mm
77measx outline_B.__2 << outline.__1 A1/2-1.5mm
78meas outline_B.__3 >> outline_B.__2 -b/2
79

Archive Download this file

Branches:
master



interactive