2 * Copyright © 2012 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; version 2 of the License.
8 * This program is distributed in the hope that it will be useful, but
9 * WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 * General Public License for more details.
13 * You should have received a copy of the GNU General Public License along
14 * with this program; if not, write to the Free Software Foundation, Inc.,
15 * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
18 load "../footprint.5c"
21 real hole_spacing = 3;
22 real hole_diameter = 0.9;
23 real hole_x = hole_spacing / 2;
25 real pad_height = 1.5;
28 real hold_height = 0.8;
30 real hold_x = 6.3 / 2 + 1/2;
31 real package_width = 6.7;
32 real package_height = 2.6;
33 real outline_x = package_width / 2;
34 real outline_y = package_height / 2;
36 real switch_travel = 1.5;
37 real switch_width = 1.3;
38 real switch_height = 1.5;
39 real switch_x = switch_travel / 2 - switch_width / 2;
40 real switch_y = package_height / 2;
50 element_start("cus-12");
53 pad_mm (pad_1_x, -(pad_y - pad_height / 2),
54 pad_width, pad_height,
58 pad_mm (pad_2_x, -(pad_y - pad_height / 2),
59 pad_width, pad_height,
62 pad_mm (pad_3_x, -(pad_y - pad_height / 2),
63 pad_width, pad_height,
66 pad_mm (-hold_x, -hold_y,
67 hold_width, hold_height,
70 pad_mm (hold_x, -hold_y,
71 hold_width, hold_height,
74 pad_mm (-hold_x, hold_y,
75 hold_width, hold_height,
78 pad_mm (hold_x, hold_y,
79 hold_width, hold_height,
82 pin_mm (-hole_x, hole_y, hole_diameter,
85 pin_mm (hole_x, hole_y, hole_diameter,
88 rect (-outline_x, -outline_y, outline_x * 2, outline_y * 2);
89 rect (switch_x, switch_y, switch_width, switch_height);