2 * Copyright © 2018 Keith Packard <keithp@keithp.com>
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation, either version 2 of the License, or
7 * (at your option) any later version.
9 * This program is distributed in the hope that it will be useful, but
10 * WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * General Public License for more details.
23 string name = sprintf("m50-35-%d", pins);
25 real pad_width = 0.74;
26 real pad_height = 1.30;
27 real package_extra_width = 1.67;
28 real pad_spacing = 1.27;
29 real total_height = 3.60;
31 real package_height = 1.80;
32 real package_width = 1.27 * (pins - 1) + package_extra_width;
34 real pad_gap = total_height - (pad_height * 2);
35 real pad_y_center = pad_gap / 2 + pad_height / 2;
45 return (- (pins-1) / 2) * pad_spacing + (n-1) * pad_spacing;
50 pad_mm(pad_x(n), pad_y(n), pad_width, pad_height,
57 rect(-package_width / 2, -package_height / 2, package_width, package_height);
59 for (int i = 1; i <= pins; i++)