This video was used as a reference for this guide.
For demonstration we will be using the KiCad Footprint wizard to generate a footprint for LM317BT.
Open KiCad and Footprint Editor.
Figure |
Go to file -> New Footprint…
Figure |
Enter the footprint name (Package name. For example: TO-220) and select the Through hole footprint type.
Figure |
Create a new footprint library for your project.
Figure |
Figure |
Figure |
It’s probably a good idea at this early stage in your PCB design career to associate your footprint library with your project. You may make different decisions later.*
Select the library folder you generated.
Figure |
Save the footprint in the new footprint library.
Figure |
In the editor make sure to select mm as the units, because the data sheet we are using is in mm. Please note that for most through-hole components it is preferred to use mils
Mil refers to 1/1000^th^ of an inch
Figure |
Move the footprint name to the bottom and REF** to the top. To move them select them with the mouse and press the M key or left click to drag.
The default grid is 100mils (2.5400mm) which can be adjusted in the drop down at the top of the editor.
Figure |
Now take a look at the datasheet for the TO-220 package the LM317BT regulator comes in. Find the Mechanical Case Outline that includes the package dimensions.
Figure |
Variable “G” indicates pin pitch, with a minimum of 2.42mm and a maximum of 2.66mm. We will take the average to ensure the pin pitch is correct. The maximum pin pitch will be 2.54mm.
Adjust the grid spacing to match the pin pitch. Now when you place your pads they will be spaced correctly to the datasheet.
Figure |
You can also create a user defined grid for non-standard parts
Figure |
Variable “D” on the TO-220 Mechanical Case Outline indicates pin width, with a minimum of 0.64mm and a maximum of 0.88mm. We will take the average to ensure the pin width is correct. The maximum pin thickness will be 0.76mm.
If the maximum width $w$ is 0.88mm and the maximum thickness t is 0.76mm, then the maximum possible hypotenuse $h$ is $h\ = \ (w\hat{}2 + t\hat{}2)\hat{}(1/2)$, or 1.16mm. Setting the drill size to that maximum possible value will ensure all parts fit, though there may be some slop in standard parts. This ensures the tolerances on a given part fit the footprint.
dimensions |
Open the Pad Properties window by pressing the pad icon with a gear next to it.
Figure |
In the Pad Properties window. Make sure the type selected is Through-hole. Change Pad number to 2. Set the pad shape to circular. For hole size use the derived 1.16mm from part 13 to ensure all parts will fit together.
The Pad shape refers to the copper conductor you will be soldering your component on to.
Overlapping and small pads are bad practice and can lead to a short or the pads being stripped off of the PCB.* The DFM check (upcoming tutorial) will also help you understand your limits.
Figure |
Press ok to exit the window and select the add a pad button on the right side.
Figure |
Place the pad at the origin.
Figure |
Now go back to the Pad Properties window and change the Pad number to a 1.
Place that pad to the left of pad 2 then place pad 3 to the right of pad.
Figure |
Figure |
To draw the outline of the package we will select the rectangle option on the right and select the F. silkscreen (Front/Top Silkscreen) from the drop town on the top tool bar.
Figure |
Draw the bounding rectangle and adjust the positioning of the REF** and footprint name.
Figure |
You now have a basic footprint you can save and use.