Update wiki pages
[geda-gaf.git] / docs / wiki / geda-pcb_footprints.html
blob08a1e1cbe125d3c31ea4a10bb1023601bc05d9da
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3 <html>
4 <head>
5 <link rel="stylesheet" media="screen" type="text/css" href="./style.css" />
6 <link rel="stylesheet" media="screen" type="text/css" href="./design.css" />
7 <link rel="stylesheet" media="print" type="text/css" href="./print.css" />
9 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
10 </head>
11 <body>
13 <p>
14 <em>Translations of this page are also available in the following languages:</em> <a href="geda-pcb_footprints.ru.html" class="wikilink1" title="geda-pcb_footprints.ru.html">Русский</a>.
15 </p>
17 <h1 class="sectionedit1" id="pcb_footprint_guides">PCB Footprint Guides</h1>
18 <div class="level1">
19 <ul>
20 <li class="level1"><div class="li"> Stuart Brorson&#039;s <a href="http://wiki.geda-project.org/_media/geda:land_patterns_20070818.pdf" class="urlextern" title="http://wiki.geda-project.org/_media/geda:land_patterns_20070818.pdf" rel="nofollow">footprint guide</a></div>
21 </li>
22 <li class="level1"><div class="li"> <a href="http://pcb.geda-project.org/pcb-cvs/pcb.html" class="urlextern" title="http://pcb.geda-project.org/pcb-cvs/pcb.html" rel="nofollow">PCB manual</a></div>
23 </li>
24 <li class="level1"><div class="li"> <a href="geda-pcb-quick_reference.html#footprint_reference" class="wikilink1" title="geda-pcb-quick_reference.html">The PCB Quick-Reference</a></div>
25 </li>
26 <li class="level1"><div class="li"> <a href="geda-pcb_footprint_naming_conventions.html" class="wikilink1" title="geda-pcb_footprint_naming_conventions.html">PCB Footprint Naming Conventions</a> : read this to learn how to <em>name</em> your footprint files.</div>
27 </li>
28 <li class="level1"><div class="li"> <a href="geda-pcb_tips.html" class="wikilink1" title="geda-pcb_tips.html"> The PCB FAQ.</a></div>
29 </li>
30 </ul>
32 </div>
33 <!-- EDIT1 SECTION "PCB Footprint Guides" [117-545] -->
34 <h3 class="sectionedit2" id="footprint_basics">Footprint basics</h3>
35 <div class="level3">
36 <ul>
37 <li class="level1"><div class="li"> There are two types of footprints: M4 and NEWLIB.</div>
38 </li>
39 <li class="level1"><div class="li"> The best tools for creating footprints are PCB (wysiwyg), TEXT EDITOR (fast, accurate), SCRIPTING (powerful).</div>
40 </li>
41 <li class="level1"><div class="li"> <strong>For drawing footprints in PCB</strong>, refer to the <a href="http://pcb.geda-project.org/pcb-cvs/pcb.html#Library-Creation" class="urlextern" title="http://pcb.geda-project.org/pcb-cvs/pcb.html#Library-Creation" rel="nofollow">section about library creation in the PCB manual</a>, look at the part “Creating Newlib Footprints” in the “New Style Libraries” subsection.</div>
42 </li>
43 <li class="level1"><div class="li"> <strong>For writing footprints in text</strong>, refer to <a href="http://wiki.geda-project.org/_media/geda:land_patterns_20070818.pdf" class="urlextern" title="http://wiki.geda-project.org/_media/geda:land_patterns_20070818.pdf" rel="nofollow">Footprint Creation for the Open-Source Layout Program &quot;PCB&quot;</a> written and maintained by Stuart Brorson.</div>
44 </li>
45 <li class="level1"><div class="li"> <strong>For Scripting footprints</strong> see the <a href="pcb-footprint_generators.html" class="wikilink1" title="pcb-footprint_generators.html">footprint generators</a> page.</div>
46 </li>
47 <li class="level1"><div class="li"> Other things you may find helpful: calculator, paper+pencil, datasheets, calipers, spreadsheet.</div>
48 </li>
49 </ul>
51 </div>
52 <!-- EDIT2 SECTION "Footprint basics" [546-1401] -->
53 <h3 class="sectionedit3" id="manufacturer_references_for_laying_out_footprints">Manufacturer references for laying out footprints</h3>
54 <div class="level3">
55 <ul>
56 <li class="level1"><div class="li"> <a href="http://www.nxp.com/package" class="urlextern" title="http://www.nxp.com/package" rel="nofollow">http://www.nxp.com/package</a></div>
57 </li>
58 <li class="level1"><div class="li"> <a href="http://focus.ti.com/general/docs/packaging.jsp" class="urlextern" title="http://focus.ti.com/general/docs/packaging.jsp" rel="nofollow">http://focus.ti.com/general/docs/packaging.jsp</a></div>
59 </li>
60 <li class="level1"><div class="li"> <a href="http://www.maxim-ic.com/design/packaging/" class="urlextern" title="http://www.maxim-ic.com/design/packaging/" rel="nofollow">http://www.maxim-ic.com/design/packaging/</a></div>
61 </li>
62 <li class="level1"><div class="li"> <a href="http://www.national.com/packaging/folders/pkg_index.html" class="urlextern" title="http://www.national.com/packaging/folders/pkg_index.html" rel="nofollow">http://www.national.com/packaging/folders/pkg_index.html</a></div>
63 </li>
64 <li class="level1"><div class="li"> <a href="http://www.irf.com/package/" class="urlextern" title="http://www.irf.com/package/" rel="nofollow">http://www.irf.com/package/</a></div>
65 </li>
66 <li class="level1"><div class="li"> <a href="http://www.onsemi.com/PowerSolutions/supportTechDoc.do?id=1165" class="urlextern" title="http://www.onsemi.com/PowerSolutions/supportTechDoc.do?id=1165" rel="nofollow">http://www.onsemi.com/PowerSolutions/supportTechDoc.do?id=1165</a></div>
67 </li>
68 <li class="level1"><div class="li"> <a href="http://www.analog.com/Analog_Root/Packages/Packages_Home/" class="urlextern" title="http://www.analog.com/Analog_Root/Packages/Packages_Home/" rel="nofollow">http://www.analog.com/Analog_Root/Packages/Packages_Home/</a></div>
69 </li>
70 <li class="level1"><div class="li"> <a href="http://www.linear.com/designtools/PkgInfo.jsp" class="urlextern" title="http://www.linear.com/designtools/PkgInfo.jsp" rel="nofollow">http://www.linear.com/designtools/PkgInfo.jsp</a></div>
71 </li>
72 </ul>
74 </div>
75 <!-- EDIT3 SECTION "Manufacturer references for laying out footprints" [1402-1862] -->
76 <h3 class="sectionedit4" id="sharing_pcb_footprints">Sharing PCB Footprints</h3>
77 <div class="level3">
78 <ul>
79 <li class="level1"><div class="li"> The place to share symbols and footprints is <a href="http://www.gedasymbols.org" class="urlextern" title="http://www.gedasymbols.org" rel="nofollow"> gedasymbols.org</a></div>
80 </li>
81 </ul>
82 <ul>
83 <li class="level1"><div class="li"> You can find many PCB footprints at <a href="http://www.luciani.org/geda/pcb/pcb-footprint-list.html" class="urlextern" title="http://www.luciani.org/geda/pcb/pcb-footprint-list.html" rel="nofollow">John Luciani&#039;s footprint page</a></div>
84 </li>
85 </ul>
86 <ul>
87 <li class="level1"><div class="li"> You can share <a href="http://opencircuits.com/PCB_Footprints" class="urlextern" title="http://opencircuits.com/PCB_Footprints" rel="nofollow"> gEDA footprints at Open Circuits</a>.</div>
88 </li>
89 </ul>
91 </div>
92 <!-- EDIT4 SECTION "Sharing PCB Footprints" [1863-2224] -->
93 <h3 class="sectionedit5" id="pcb_footprint_faq">PCB Footprint FAQ</h3>
94 <div class="level3">
96 </div>
98 <h4 id="how_do_pcb_s_footprints_work">How do PCB&#039;s footprints work?</h4>
99 <div class="level4">
102 PCB supports two entirely separate footprint library mechanisms:
103 </p>
104 <ol>
105 <li class="level1"><div class="li"> The first is referred to as the “oldlib”, “pcblib”, or the “M4 library”. This system uses the macro language M4 to generate footprints on the fly. The M4 library is fairly large. A powerful feature of the m4 library is that an entire family of footprints can quickly be defined by defining an appropriate base macro. Several standard families of footprints exist in pcblib. Starting with the pcb-20070208 snapshot, the entire m4 library is available as “newlib” footprints (see the following paragraph) under the name “pcblib-newlib”.</div>
106 </li>
107 <li class="level1"><div class="li"> The second footprint library for PCB is called the “newlib”. Newlib footprints are defined using <abbr title="American Standard Code for Information Interchange">ASCII</abbr> text files which call out each graphical primitive which makes up an entire footprint. Newlib footprints can either be created graphically using PCB or via any other method which can produce a text file (text editor, awk/perl/ruby script, etc.). The use of a scripting or programming language is especially powerful because you can generate large footprints or families of footprints.</div>
108 </li>
109 </ol>
112 Therefore, during layout, you can use footprints which are distributed with
113 PCB, you can find footprints via a web search, or you can create your own, and
114 put them in a dedicated directory. <a href="http://pcb.geda-project.org/pcb-cvs/pcb.html" class="urlextern" title="http://pcb.geda-project.org/pcb-cvs/pcb.html" rel="nofollow">The pcb manual</a> has complete and up to date documentation for the element file format. <a href="http://gedasymbols.org" class="urlextern" title="http://gedasymbols.org" rel="nofollow">Gedasymbols.org</a> has a number of user contributed footprints. A somewhat incomplete but useful tutorial is available on the web at: <a href="http://www.brorson.com/gEDA/" class="urlextern" title="http://www.brorson.com/gEDA/" rel="nofollow">http://www.brorson.com/gEDA/</a> (search for the term “newlib”).
115 </p>
117 </div>
119 <h4 id="where_can_i_get_pre-drawn_footprints_for_pcb">Where can I get pre-drawn footprints for PCB?</h4>
120 <div class="level4">
121 <ul>
122 <li class="level1"><div class="li"> Check your hard disk for <code>newlib</code> and <code>pcblib-newlib</code>. These directories contain the default footprint library of PCB.</div>
123 </li>
124 <li class="level1"><div class="li"> The best place to get additional footprints is the <a href="http://www.gedasymbols.org" class="urlextern" title="http://www.gedasymbols.org" rel="nofollow">gEDA Symbols website</a>. If you have you are welcome to contribute to the project and share your footprints.</div>
125 </li>
126 <li class="level1"><div class="li"> <a href="http://www.luciani.org/geda/pcb/pcb-footprint-list.html" class="urlextern" title="http://www.luciani.org/geda/pcb/pcb-footprint-list.html" rel="nofollow">John Luciani&#039;s website</a> has a large number of footprints and tools.</div>
127 </li>
128 <li class="level1"><div class="li"> Darrell Harmon provides a nice footprint generating script <a href="http://www.dlharmon.com/geda/footgen.html" class="urlextern" title="http://www.dlharmon.com/geda/footgen.html" rel="nofollow">on his website</a>.</div>
129 </li>
130 <li class="level1"><div class="li"> Kicad footprints (called “modules” there) can be converted to PCB footprints with the <a href="https://github.com/erichVK5/KicadModuleToGEDA" class="urlextern" title="https://github.com/erichVK5/KicadModuleToGEDA" rel="nofollow">utility</a> by Erich Heinzle.</div>
131 </li>
132 <li class="level1"><div class="li"> Finally, you can ask on the <a href="http://wiki.geda-project.org/geda:mailinglists" class="urlextern" title="http://wiki.geda-project.org/geda:mailinglists" rel="nofollow">geda-user mailing list</a>, and somebody might take pity on you and send you a footprint.</div>
133 </li>
134 </ul>
136 </div>
138 <h4 id="i_want_to_use_pcb_to_do_layout_how_do_i_know_what_value_to_use_for_the_footprint_attribute">I want to use PCB to do layout. How do I know what value to use for the footprint attribute?</h4>
139 <div class="level4">
142 This question is a common one amongst new gEDA users. Indeed, helping newbies determine the appropriate footprint names lies at the core of the ongoing <a href="geda-faq-gschem.html#what_s_this_business_about_heavy_vs._light_symbols" class="wikilink1" title="geda-faq-gschem.html">light vs. heavy symbol</a> debate. In the current, light symbol gEDA/gaf distribution, you need to attach the footprint attribute at the schematic level (i.e. using either gschem or gattrib). The name of the footprint to use depends upon whether you are using the newlib or the M4 library (pcblib).
143 </p>
145 </div>
147 <h4 id="newlib">Newlib</h4>
148 <div class="level4">
151 The newlib stores one footprint per file, and the footprint names used by the newlib are the file names of the footprint files.
152 </p>
155 There are several ways to determine the newlib footprint names to use:
156 </p>
157 <ul>
158 <li class="level1"><div class="li"> You can browse the available footprints by running pcb and opening the footprint library window (available from the menu bar via <strong><em>Window</em></strong><strong><em>Library</em></strong>). Click on the “newlib” library group, and then select a sublibrary to browse its symbols. The name of each footprint appears in the <strong>Elements</strong> window on the right hand side of the footprint library browser. Use the name exactly as it appears in the browser for the footprint attribute in gschem or gattrib.</div>
159 </li>
160 <li class="level1"><div class="li"> The newlib footprints distributed with PCB are stored in the directories under <strong><code>${PREFIX}/share/pcb/newlib</code></strong>. (<strong><code>${PREFIX}</code></strong> is the install directory you specified when configuring/building PCB.) The name to stick in the “footprint” attribute is the filename of the footprint you wish to use.<br/>
161 For example, on my machine I installed gEDA with the prefix <strong><code>/usr/local/geda/</code></strong>. The 0805 package (for SMT resistors or caps) lives in a file with absolute path<br/>
162 <strong><code>/usr/local/geda/share/pcb/newlib/generic_SMD_packages/0805_reflow_solder</code></strong> <br/>
163 Therefore, to use this footprint on a component I set its “footprint” attribute to <strong><code>0805_reflow_solder</code></strong> using gschem or gattrib.<br/>
164 Note that if the newlib symbol you want to use lives in a non-standard directory, gsch2pcb needs you to specify a path to that directory, either within your project.rc file (if you use one) or using the <strong><code>--elements-dir</code></strong> flag (from the command line).</div>
165 </li>
166 <li class="level1"><div class="li"> Finally, since each new design typically requires you to draw at least a couple of new footprints, it’s likely you will have a local “footprints” directory. As previously, the footprint name to use is the filename you assign to each of your new footprints. Again, don’t forget to add a line to your project.rc file telling gsch2pcb where to find your local footprints. Alternately, you can run gsch2pcb with the <strong><code>--elements-dir</code></strong> flag set to point to your local footprint directory.</div>
167 </li>
168 </ul>
170 </div>
172 <h4 id="m4_library">M4 library</h4>
173 <div class="level4">
176 The M4 library stores the footprints as M4 macros; there are usually several (many) footprints contained in each footprint file. The different footprints in a single file are generally variations on a single pattern (e.g. DIP-8, DIP-14, DIP-16, etc.) The easiest way to find the correct footprint attribute name is by browsing through the “pcblib” library in the PCB library window. The footprint attribute is given in square brackets in the description. Also you can view the list of footprints from pcblib at the <a href="http://www.gedasymbols.org/footprints/" class="urlextern" title="http://www.gedasymbols.org/footprints/" rel="nofollow">gEDA Symbols webpage</a>.
177 </p>
180 The following m4 libraries have received more attention and improvements than the others:
181 </p>
182 <ul>
183 <li class="level1"><div class="li"> ~amp for Amp connectors</div>
184 </li>
185 <li class="level1"><div class="li"> ~amphenol for Amphenol connectors</div>
186 </li>
187 <li class="level1"><div class="li"> ~geda for many diverse parts used in basic design using gEDA (resistors, caps, etc).</div>
188 </li>
189 <li class="level1"><div class="li"> ~bourns for products like trim pots from Bourns</div>
190 </li>
191 <li class="level1"><div class="li"> ~cts for products like resistor packs from CTS</div>
192 </li>
193 <li class="level1"><div class="li"> ~johnstech for Johnstech sockets</div>
194 </li>
195 <li class="level1"><div class="li"> ~minicircuits for Minicircuits specific footprints</div>
196 </li>
197 <li class="level1"><div class="li"> ~panasonic for some Panasonic specific footprints</div>
198 </li>
199 </ul>
202 Finally, for both the newlib and the M4 lib, it is extremely important that you verify that the footprint name you use instantiates *exactly* the footprint you want when you place it in PCB. Therefore, it is critical to inspect the footprint before you use it. You can verify the footprint you want to use by clicking on it in the “footprint library” window, and then placing it onto an empty spot in PCB’s drawing area. Manually inspect the footprint to ensure that it has the correct number of pins/pads, correct dimensions, etc.
203 </p>
206 Also, once you generate Gerber files, make sure you <a href="geda-pcb_tips.html#i_m_done_with_my_layout._how_should_i_check_my_design" class="wikilink1" title="geda-pcb_tips.html">inspect all footprints instantiated in your Gerbers</a> using gerbv (or an equivalent Gerber viewer) before you send your design out for fabrication.
207 </p>
209 </div>
211 <h4 id="what_is_the_recommended_way_to_deal_with_different_footprints_for_the_same_sort_of_device">What is the recommended way to deal with different footprints for the same sort of device?</h4>
212 <div class="level4">
215 For example, an opamp may be DIP8 or SO8. A resistor may be 0603, 0805, 1208, or through-hole. How do I know what package and footprint to use, and how do I manage the choices?
216 </p>
219 First off, the footprint you should use is a decision for you to make, not your CAD tool. It is up to you to choose your preferred package type/footprint, and then attach the correct footprint attribute to the component in the schematic. Once you have chosen which package (and footprint) you wish to use, then either <a href="geda-pcb_tips.html#where_can_i_get_pre-drawn_footprints_for_pcb" class="wikilink1" title="geda-pcb_tips.html">find an appropriate footprint</a>, or <a href="geda-pcb_tips.html#how_do_i_draw_a_new_footprint" class="wikilink1" title="geda-pcb_tips.html">draw one yourself</a> and save it in a local directory.
220 </p>
223 As far as managing the footprint choices (and indeed the large number of component attributes you are likely to have): Use <a href="geda-faq-attribs.html#help_my_design_has_hundreds_of_components_and_it_s_a_pain_to_use_gschem_to_attach_all_my_attributes" class="wikilink1" title="geda-faq-attribs.html">gattrib</a>. That’s what it’s for.
224 </p>
226 </div>
228 <h4 id="how_do_i_draw_a_new_footprint">How do I draw a new footprint?</h4>
229 <div class="level4">
232 Everybody does this a little differently. Some people draw the footprint entirely using PCB. Some people first draw a preliminary footprint in PCB, and then finish it off by hand editing it (e.g. using emacs). Some people write Perl or Python scripts to autogenerate footprints.
233 </p>
234 <ul>
235 <li class="level1"><div class="li"> use a text editor. See <a href="http://wiki.geda-project.org/_media/geda:land_patterns_20070818.pdf" class="urlextern" title="http://wiki.geda-project.org/_media/geda:land_patterns_20070818.pdf" rel="nofollow"> the manual on footprint creation</a> by Stuart Brorson for the details.</div>
236 </li>
237 <li class="level1"><div class="li"> draw the part in PCB and save as a footprint. See the <a href="http://ronja.twibright.com/guidelines/footprints.php" class="urlextern" title="http://ronja.twibright.com/guidelines/footprints.php" rel="nofollow">howto by Karel Kulhavy</a></div>
238 </li>
239 <li class="level1"><div class="li"> or use a <a href="http://dlharmon.com/geda/footgen.html" class="urlextern" title="http://dlharmon.com/geda/footgen.html" rel="nofollow"> python script</a> by Darrel Harmon for “two pad”, “SOxx”, “tabbed” and QFP“ style</div>
240 </li>
241 <li class="level1"><div class="li"> or use a <a href="http://www.brorson.com/gEDA" class="urlextern" title="http://www.brorson.com/gEDA" rel="nofollow"> perl script</a> by Stuart Brorson for two pad SMT components</div>
242 </li>
243 <li class="level1"><div class="li"> or use a <a href="http://www.luciani.org/geda/pcb/pcb-perl-library.html" class="urlextern" title="http://www.luciani.org/geda/pcb/pcb-perl-library.html" rel="nofollow">perl script</a> from John Luciani – can be adapted to DIL, SOxx-Style, QFP, or even circular arrangement of pads.</div>
244 </li>
245 <li class="level1"><div class="li"> or use the web based application <a href="http://www.gedasymbols.org/user/dj_delorie/tools/dilpad.html" class="urlextern" title="http://www.gedasymbols.org/user/dj_delorie/tools/dilpad.html" rel="nofollow">dilpad</a> written by DJ Delorie for “SOxx” style footprints.</div>
246 </li>
247 </ul>
249 </div>
251 <h4 id="how_do_i_edit_change_an_existing_footprint">How do I edit/change an existing footprint?</h4>
252 <div class="level4">
255 You can convert a footprint into an ordinary layout, edit the parts and convert them back to footprint. In the following list the parts in bold italic font are actions from the <strong><em>Buffer</em></strong> menu.
256 </p>
257 <ol>
258 <li class="level1"><div class="li"> Select element</div>
259 </li>
260 <li class="level1"><div class="li"> Copy selection to buffer (<kbd>Ctrl</kbd>+<kbd>C</kbd>).</div>
261 </li>
262 <li class="level1"><div class="li"> <strong><em>Break buffer elements to pieces</em></strong>. Pins become vias and pads become tracks. Unfortunately, some information is lost during the process. Namely, the square flag names of pins and pads. You have to regenerate this information later.</div>
263 </li>
264 <li class="level1"><div class="li"> <strong><em>Paste buffer to layout</em></strong></div>
265 </li>
266 <li class="level1"><div class="li"> Do the desired changes. Note, that only vias, tracks and rectangles are allowed. No text, no arcs, no general polygons.</div>
267 </li>
268 <li class="level1"><div class="li"> Select all objects that belong to the footprint</div>
269 </li>
270 <li class="level1"><div class="li"> Copy selection to buffer (<kbd>Ctrl</kbd>+<kbd>C</kbd>). The position of the crosshair will determine the origin of the resulting footprint. The origin will be marked with a little diamond.</div>
271 </li>
272 <li class="level1"><div class="li"> <strong><em>Convert buffer to element</em></strong>. This converts vias to pins. Tracks and rectangles get SMD pads.</div>
273 </li>
274 <li class="level1"><div class="li"> <strong><em>Paste buffer to layout</em></strong></div>
275 </li>
276 <li class="level1"><div class="li"> Place the mouse over the pads that got rounded during step 4 and press <kbd>Q</kbd>. This squares off the rounded pad edges.</div>
277 </li>
278 <li class="level1"><div class="li"> Go over every pad, press <kbd>N</kbd> and give a name to the pad.</div>
279 </li>
280 <li class="level1"><div class="li"> Place the mouse somewhere where there is no pad or pin and give a name to the symbol.</div>
281 </li>
282 <li class="level1"><div class="li"> Move the name to the place where you want the refdes or the value to appear.</div>
283 </li>
284 <li class="level1"><div class="li"> Select everything and copy selection to buffer (<kbd>Ctrl</kbd>+<kbd>C</kbd>)</div>
285 </li>
286 <li class="level1"><div class="li"> <strong><em>Save buffer elements to file</em></strong>.</div>
287 </li>
288 </ol>
291 Alternatively, you can use your favorite text editor and edit the source code of the footprint.
292 </p>
294 </div>
296 <h4 id="how_do_i_move_the_diamond_of_a_footprint">How do I move the diamond of a footprint</h4>
297 <div class="level4">
300 The origin of a footprint is marked with a little diamond. To move it to some other position relative to the footprint you have to modify all coordinates. This can be done manually with a text editor. If you want to do it from within the <abbr title="Graphical User Interface">GUI</abbr>, you need to break the footprint into pieces and assemble it again. See above for a detailed checklist. Note, that the position of the diamond is determined by the position of cross hair when copying to the buffer.
301 </p>
304 Yes, this is tedious. The reason for it is the lack of a real footprint editing mode in pcb. You are invited to write one.
305 </p>
307 </div>
309 <h4 id="pcb_does_not_save_silk_when_i_try_to_make_a_footprint">pcb does not save silk when I try to make a footprint</h4>
310 <div class="level4">
313 The silk of footprints can only deal with lines and arcs. All the other objects like polygons, rectangles and text are silently omitted during <strong><em>Convert buffer to element</em></strong>. If you need text in footprints you have to literally draw the letters with the line tool.
314 Or, use this
315 <a href="https://github.com/erichVK5/FootprintTextForPCB" class="urlextern" title="https://github.com/erichVK5/FootprintTextForPCB" rel="nofollow">utility</a> by
316 Erich Heinzle to create silkscreen line elements for any given
317 <abbr title="American Standard Code for Information Interchange">ASCII</abbr> text, which can then be added to an existing footprint.
318 </p>
320 </div>
322 <h4 id="what_is_the_proper_way_to_make_a_double-sided_footprint">What is the proper way to make a double-sided footprint?</h4>
323 <div class="level4">
326 You can use the “onsolder” flag to place pads on the opposite side of the
327 board. You would have something like this for a connector on both sides of the board:
328 </p>
329 <pre class="code">Pad[-40000 -7000 -40000 7000 2700 2400 3000 &quot;B1&quot; &quot;B1&quot; &quot;square&quot;]
330 Pad[-40000 -7000 -40000 3000 2700 2400 3000 &quot;A1&quot; &quot;A1&quot; &quot;square,onsolder&quot;]</pre>
333 If you draw the footprint with pcb-<abbr title="Graphical User Interface">GUI</abbr> and do <strong><em>Buffer</em></strong><strong><em>Convert buffer to element</em></strong>, the lines on the second layer become pads with the onsolder flag. Yes, it is the second layer, regardless its name.
334 </p>
336 </div>
338 <h4 id="how_can_i_achieve_pads_without_paste">How can I achieve pads without paste?</h4>
339 <div class="level4">
342 Sometimes, exposed copper should not receive solder paste. A common example is the pads of an edge connector. This can be achieved with the <code>nopaste</code> <a href="geda-glossary.html#flag" class="wikilink1" title="geda-glossary.html">flag</a>. Currently, there is no <abbr title="Graphical User Interface">GUI</abbr> way to set the flag. Use a text editor to add this flag to the pads of a footprint.
343 </p>
345 </div>
347 <h4 id="how_do_i_add_a_footprint_library_to_pcb">How do I add a footprint library to PCB?</h4>
348 <div class="level4">
351 Adding footprint libraries can be done from the <abbr title="Graphical User Interface">GUI</abbr>:<br/>
353 <strong><em>File</em></strong><strong><em>Preferences…</em></strong><strong>Library</strong><code>FOOTPRINTDIRECTORY</code><br/>
355 Alternatively you can edit the file <code>$HOME/.pcb/preferences</code>. Make sure, no instance of pcb is currently running. Look for the line that starts with “library-newlib”.
356 Don’t forget to include the new directory into either your gsch2pcbrc, or your local gafrc file (if you are using gsch2pcb, that is).
357 </p>
359 </div>
361 <h4 id="how_do_i_update_a_footprint_in_my_layout">How do I update a footprint in my layout?</h4>
362 <div class="level4">
365 There is no way to automatically replace all instances of a footprint with the new version, yet. But there is a special mode of the buffer-paste tool, that will reduce the amount of clicks for manual replacement.<br/>
367 Use the <strong><em>Window</em></strong><strong><em>Library</em></strong> dialog box to manually choose the new footprint. The tool becomes the buffer-paste tool, with the new footprint preloaded. Rotate it if needed with <strong><em>Buffer</em></strong><strong><em>Rotate Buffer</em></strong>. Position the new footprint over the old one, and shift-left-mouse-click to replace the old footprint with the new one. Watch out for being 180 degrees off, use <kbd>O</kbd> to check the rats nest after each placement, and undo if it appears you placed it backwards.
368 </p>
370 </div>
372 <h4 id="pcb_is_not_finding_my_footprints_why">PCB is not finding my footprints. Why?</h4>
373 <div class="level4">
376 The footprint path that PCB uses is defined using the <strong><code>Pcb.elementPath</code></strong> variable in the app-defaults file named <strong><code>PCB</code></strong>. The path for the <strong><code>PCB</code></strong> file is set using the <strong><code>XAPPLRESDIR</code></strong> environment variable which is typically set from within the wrapper script named <strong><code>pcb</code></strong>.
377 </p>
379 </div>
381 <h4 id="now_that_i_have_all_of_these_footprints_where_do_i_put_them">Now that I have all of these footprints where do I put them?</h4>
382 <div class="level4">
385 I prefer to place all “production-ready” footprints in a single directory that is not in the gEDA/PCB install tree. When a new version of gEDA/PCB comes out I do not make any changes to project files or libraries. If there are newlib footprints in the PCB library that I want to use I copy them to the “production-ready” footprint directory.
386 </p>
389 Rather than change configuration files to get gsch2pcb to find the footprints I create a wrapper script called <strong><code>sch2pcb</code></strong> that contains the footprint path. All users use the same script and access the same production footprints.
390 </p>
393 To use the <strong><code>sch2pcb</code></strong> script that is listed below replace the string <strong><code>FOOTPRINT_DIR</code></strong> with your footprint directory:
394 </p>
395 <pre class="code">#!/bin/bash
396 gsch2pcb --elements-dir FOOTPRINT_DIR $@</pre>
399 Or another user&#039;s version:
400 </p>
401 <pre class="code">#!/bin/bash
402 #this script was written by John Luciani
403 gsch2pcb --elements-dir /home/user/pcb/footprints/user --use-files $@</pre>
406 Alternatively you can make use of a project file which gsch2pcb reads for its options. For example the file <code>myproject</code> could look like this:
407 </p>
408 <pre class="code">schematics myschematic.sch myschematic2.sch
409 elements-dir /myfootprintdir
410 output-name mypcb
411 skip-m4</pre>
414 The example file searches through <code>myfootprintdir</code> for footprints used in <code>myschematic.sch</code> and <code>myschematic2.sch</code> and creates <code>mypcb.pcb</code> skipping m4 style footprints. gsch2pcb is then called with the project file as an option.
415 </p>
416 <pre class="code">gsch2pcb myproject</pre>
418 </div>
420 <h4 id="can_i_have_two_pads_pins_with_the_same_pin-number">Can I have two pads/pins with the same pin-number?</h4>
421 <div class="level4">
424 “Yes, totally. This is how you create oval shaped copper around pins, or funny shaped pads (e.g. square at one end and round at the other) by overlapping two or more pads.”
425 </p>
427 </div>
429 <h4 id="how_do_i_make_an_oval_shaped_pad_around_a_footprint_pin">How do I make an oval shaped pad around a footprint pin?</h4>
430 <div class="level4">
433 Simply add a pad on top of your pin and give them the same pin-number. If the soldermask is kept off both pins, and they overlap, they should appear as one pin on your board.
434 </p>
436 </div>
438 <h4 id="how_do_i_make_a_2-sided_pad">How do I make a 2-sided pad?</h4>
439 <div class="level4">
442 “Odd as it sounds, this can be necessary for some edge connectors. … but how do you do it???”
443 </p>
446 You can do it by making two pads at the same position and same pin number,
447 but the second one with the flag “onsolder”. Like in:
448 </p>
449 <pre class="code">Pad[ 10mm -3mm 10mm 3mm 2.0mm 0.5mm 0.2mm &quot;1&quot; &quot;1&quot; &quot;square&quot; ]
450 Pad[ 10mm -3mm 10mm 3mm 2.0mm 0.5mm 0.2mm &quot;1&quot; &quot;1&quot; &quot;square,onsolder&quot; ]</pre>
452 </div>
454 <h4 id="edge_connectors">Edge Connectors</h4>
455 <div class="level4">
458 Do a 2-sided pad as above. If you want the shape of the connector pad
459 to be square at the edge end and half-round at the pcb-interior end, use
460 two overlapping pads per side, like in:
461 </p>
462 <pre class="code">Pad[ 0 -3mm 0 3mm 2.0mm 0.5mm 0.2mm &quot;1&quot; &quot;1&quot; &quot;square&quot; ]
463 Pad[ 0 -3mm 0 5mm 2.0mm 0.5mm 0.2mm &quot;1&quot; &quot;1&quot; &quot;&quot; ]</pre>
464 <pre class="code">Pad[ 0 -3mm 0 3mm 2.0mm 0.5mm 0.2mm &quot;1&quot; &quot;1&quot; &quot;square,onsolder&quot; ]
465 Pad[ 0 -3mm 0 5mm 2.0mm 0.5mm 0.2mm &quot;1&quot; &quot;1&quot; &quot;onsolder&quot; ]</pre>
467 </div>
468 <!-- EDIT5 SECTION "PCB Footprint FAQ" [2225-] --></body>
469 </html>