CC Blog Design Solutions Research & Design Hub

Getting Started—PCBs

Written by Stuart Ball
A Primer on Creating Printed Circuit Boards

Whether designing and creating a printed circuit board (PCB) for a prototyping project or a company product, modern processes and tools increase the likelihood that your circuit will work the first time. In this article, I outline the steps needed to create a PCB and the tools that can help get you there. I also discuss important considerations in PCB design and construction.

  • What should I consider when designing a PCB?
  • What tools are available to help with PCB design and creation?
  • What are the reasons for using a PCB instead of a perforated board?
  • Printed circuit boards

Sometimes prototype circuits still get hand-wired on perforated board. I still do that occasionally—it makes circuit changes easy. It’s also useful when prototyping something in stages such as an audio mixer that drives an amplifier. I might try different mixer designs, and then design the combined circuit once I have a mixer and amp combination I like.

Using perfboards is not as easy as it was many years ago, because many surface mount parts won’t work on the 0.1” hole centers of these boards. You can get tiny printed circuit boards that will bring SOIC or TQFP packages out to pads on 0.1” centers, but sometimes you need to put your circuit on a printed circuit board (PCB).

Other reasons for using a PCB are when you plan to make several identical circuits, which is of course the only way to do any kind of volume manufacturing. Even if you only want one copy of a circuit, you might use a PCB to accommodate a unique part that has a hole or pad pattern that is difficult to do on a perfboard. You might need controlled-impedance traces, or you may need to sandwich traces between layers of copper for shielding. And even if you only want to build one of something, it’s often easier to lay out a PCB than it is to connect all the wires by hand.

The Tools 

Many years ago, you could go to Radio Shack and get some PCB tape or a resist pen and a bottle of ferric chloride. You would lay out the artwork directly on copper, and then etch the board using the ferric chloride solution. The etching solution would dissolve the copper except where it was covered by tape or resist ink. I did some boards that way, but I was never satisfied with the results. It’s just hard to really get it right.

The way companies did it back then was to create a photo image of the layout. The layer artworks were printed on clear film and then exposed to blank PCB boards with copper on both sides. The boards were coated with a photoresist that dissolved when exposed to UV light. The traces were opaque on the film, so the resist kept the copper from etching away where there were traces. But getting a schematic all the way to those film sheets was quite a process. And the films were subject to damage; you always had to keep backup films.

Things are simpler now. You send a set of files to the PCB manufacturer, called Gerber files (originally created by Gerber Scientific). Those files contain information in digital form describing the pads and traces, and the PCB manufacturer can use those to create an artwork. At the manufacturing end, the process is similar to what happened before, but the standardized Gerber file format means you don’t have to ship them physical artworks.

The downside to using standardized file formats is that your tools have to change. When I started in engineering, we were still drawing schematics on paper that was then manually translated to PCB layouts by a drafter/designer. Now you draw the schematic in a CAD (computer-aided design) tool, lay out the PCB using a layout tool, generate Gerber files and send them to the manufacturer electronically.

The implication of this is that you must use a tool suite that will let you draw the schematic and turn it into a PCB. There are a few tool manufacturers. I’ve used OrCAD (from Cadence), Xpedition (from Siemens), and an early version of Altium. Those tools are aimed at the corporate market and can be pricey (as in thousands of dollars). At home, I use Proteus from Labcenter Electronics. KiCad is an open-source tool that some people really like, and the price is right (free).

Some of the corporate tools are available in a trial version or a reduced-functionality version. Cadence provides a free trial of OrCAD, and Altium provides a tool called CircuitMaker. I have extensive experience with OrCAD, but I’ve never used CircuitMaker, so I can’t comment on it.

One factor to consider in choosing a tool is your libraries. You will likely make schematic symbols and footprint symbols in whatever package you use, and they may not port to a different package. I’ve been using Proteus at home ever since the days of Windows 9x, partly because I have a lot of parts I’ve created in my libraries. I did the same with OrCAD at work; I had many parts in the schematic and PCB libraries that I didn’t want to redraw.

The steps 

Schematic capture: The first step in having a PCB made, of course, is to create the schematic. This is where you will do all the electrical design work, making sure that you aren’t dissipating excessive power in a transistor, that all the timing meets specification, and so on. The portion of the toolset that you use to draw the schematic is called schematic capture.

Figure 1 is a schematic of a simple one-transistor amplifier with a fixed gain of 10. This isn’t a circuit for which you would normally make a PCB—it’s just a simple example to illustrate the concepts. To convert the schematic to a PCB, you first must assign a footprint to each component. In some cases, there may be default footprints for all the parts. In other cases, you may have to assign a footprint or even create one. In this example, I was able to use built-in footprints for all the components. 

Figure 1
Schematic of a single-transistor, fixed-gain amplifier
Figure 1
Schematic of a single-transistor, fixed-gain amplifier

In some tools, the schematic is where you will define controlled-impedance traces, wide traces for power, the uses of the different layers, and so forth. Typically a simple board will fit on one or two layers, while a more complex board will use four layers, in which power and ground planes comprise the middle two layers. A PCB can have dozens of layers, although I’ve never designed anything that needed more than eight. For a given board thickness, increasing the number of layers means that the thickness of the internal dielectric (insulating) layers gets thinner. This affects the impedance of traces and also increases the electrical coupling between traces on adjacent layers. Board thickness is typically 63mils (0.063”) although most vendors can make other thicknesses. I’ve used 93mil boards when I needed more stiffness. And 31mils is also a common thickness. Many modern electronics (think smartphones) use thin boards to minimize the thickness of the final product.

Netlist: After creating the schematic, you’ll create a netlist. The netlist generator will typically check for any errors, such as missing footprints, parts with more pins than the assigned footprint, duplicate component references, and other things. Different tools have different netlist formats, and many tools can export and use netlists from other tools. The netlist describes the footprint of each component and the interconnects. The netlist doesn’t describe how the board is routed, just the footprints used and the connections between pins and pads. Below is the netlist for one of the connections on the example circuit:

#00000,4

R3,PS,1

R4,PS,1

J1,PS,1

C1,PS,1

The #00000 indicates that this is the first net in the netlist, and it indicates that pins R3.1, R4.1, J1.1, and C1.1 are connected. There will be a numbered entry for each net in the schematic.

PCB creation: Once you have a netlist, you can create a PCB. The PCB tool will import the netlist, pull in the footprints specified there, and allow you to place the parts on the board. Some PCB tools have auto-place features that will try to optimize the placement. I usually don’t like the result and end up placing everything manually. The initial design screen will show a ratsnest that draws a straight line between all the interconnected pads. This is an aid to placement of parts; you can try to keep the lines as short as possible or group interconnected parts of the circuit together, rotating parts to minimize crossovers. As you place traces on the PCB, the ratsnest for each connection will disappear. Figure 2 is the placed components and ratsnest for the example circuit.

Figure 2 
Ratsnest view of a single-transistor amplifier PCB layout
Figure 2
Ratsnest view of a single-transistor amplifier PCB layout

Some tools (all the high-end ones) have an autoroute feature that will attempt to autoroute the connections. When a trace has to change layers (whether autorouted or placed manually) a via will be placed on the board to make the connection. Vias are drilled through and plated when the board is manufactured. It is possible to have “buried” vias where the via only appears on the layers where it is needed. Figure 3 is the completed layout of the example board. This simple circuit was all routed on one layer, so no vias were needed.

Figure 3
Final layout view of a single-transistor amplifier
Figure 3
Final layout view of a single-transistor amplifier

Gerber files: Once the layout is complete, you will generate Gerber files for the PCB vendor. Depending on the vendor, you may also need to supply a fabrication drawing, an NC drill file so numerically-controlled equipment can drill the holes, and possibly other items. Most tools can at least produce an Excellon-format drill file.

Stackup: When you create the board stackup, there are a few things you will need to specify. This may be done when the schematic is created or when the PCB is created. I’ve even sent the stackup as a text file to a board vendor. The stackup defines the number and order of layers, and sometimes the thickness of the internal dielectrics. In some cases, you can just give the vendor the total thickness and they will pick dielectrics that add up to the total you want.

Other considerations 

Copper weight: Copper weight is the thickness of the traces on a PCB layer. It’s strange to refer to thickness as weight, but the weight measurement is the weight of one square foot of copper. Common values are ½oz, which is about 0.7mils thick (0.0007”), and 1oz, which is about 1.4mils thick (0.0014”). There are other copper weights available ranging from 1/8oz to 4oz. Some PCB manufacturers have a low-cost prototype service that will provide two-layer boards at a reduced cost, and those are usually limited to ½oz or 1oz copper layers. You will need to specify the copper weight. If different layers use different copper weights, then you will need to specify that. 

Current handling: A 20-gauge wire is about 0.032” in diameter and can handle about 11A per AWG ratings. So a 0.032” wide trace can also handle 11A, right? Well, no. In a round wire, the cross-sectional area of the wire is what carries the current. A 20-gauge wire has a cross-sectional area of about 0.16”. A 0.032”, 1oz PCB trace has a cross-sectional area of about 45 microinches (0.032” x 0.0014”).

Any wire has resistance, and when current passes through it, some of the power is dissipated as heat. So when calculating the trace width needed to carry a specific current, you will normally specify the allowable temperature rise. There are online calculators that will let you put in the trace thickness and other parameters, then calculate the required trace width. Using the calculator available at Digikey [1], for 10A and a maximum 40°C temperature rise, you need a trace width of 317mils (0.317”) if using 1oz copper. If you want to limit temperature rise to 20°C, you need a trace that is almost ½” wide.

Often, current isn’t an issue on low-power designs, but you need to be aware of it if you have any high current traces on the PCB. And the current doesn’t need to be all that high; even 1A requires a minimum 13mil 1oz trace. Also, make sure the vias on the high-current traces can handle the current as well. Sometimes the default via used by the layout tool is adequate for low-current signal traces but inappropriate for higher current. You may need multiple smaller vias to handle high current. There are via current calculators available online, such as one provided by Sierra Circuits [2].

Controlled impedance: If your design connects to USB, SATA, SAS, PCIe, or any other interfaces with defined impedances, you will need to create controlled-impedance traces for those connections. For cabling such devices, you will use either coaxial or twisted-pair cable. But for connections on the PCB, you need to implement a connection using traces with a known impedance. My article “Introduction to Impedance” in Circuit Cellar issue #389 describes what impedance is and why it matters. Here I’ll just look at how it relates to PCBs.

The idea of a controlled-impedance connection is that the reactive (inductive and capacitive) portion of the impedance interacts so that the cable or PCB trace looks like a pure resistance at the frequencies of interest. Like cables, controlled-impedance traces come in two basic varieties: balanced and unbalanced. A coaxial cable with a center conductor and a shield is an unbalanced cable. A twisted pair of wires is a balanced cable, whether shielded or not. Similarly, traces on a PCB can be unbalanced or differential.

Microstrips and striplines: An unbalanced controlled-impedance trace can consist of a microstrip, which is a single trace over a ground plane (the ground plane functions the same as the shield in a coaxial cable). An unbalanced trace can also be constructed as a stripline, which is a trace sandwiched between two ground planes. Sierra Circuits has a good article that further explains the difference between microstrips and striplines [3]. 

Figure 4
Microstrip and stripline controlled-impedance configurations
Figure 4
Microstrip and stripline controlled-impedance configurations

Figure 4A is an end view of a microstrip line. The controlled-impedance trace is on the top layer, a dielectric is in the middle, and a ground plane is on the bottom layer. On a board with more than two layers, the ground plane would be on the layer adjacent to the layer with the microstrip.

The impedance of a microstrip is a function of the thickness of the trace, the width of the trace, and the material and thickness of the dielectric. Using an online calculator [4], a microstrip trace of 1oz, 120mil-wide copper on 0.063” FR4 PCB has about 52Ω impedance.  

Figure 4B is an end view of a stripline, with the trace between two ground planes. Obviously a stripline requires four or more layers, since at least three copper layers are needed. A stripline provides better shielding than a microstrip because it’s shielded on both sides.

Differential pairs: A differential pair is used to create a balanced controlled-impedance transmission line. This is used for interfaces like USB, SATA, and SAS. Figure 5 is an end view of a differential pair. Like the stripline and microstrip, the key values affecting impedance are the trace widths, height (thickness), distance from the ground plane, and dielectric constant. But for a differential pair, the trace separation is also important. It is important that the lengths of the traces in a differential pair are the same. Using an online calculator [5], a pair of 8mil traces on 63mil FR4 with 20mil trace spacing has an impedance of about 102Ω.

Figure 5
Differential pair configuration
Figure 5
Differential pair configuration

Ideally, the two traces in a differential pair are exactly parallel from one end to the other, but sometimes that’s not possible. Pins on an IC or connector may be spaced such that the trace spacing can’t be the same at both ends. This will cause a discontinuity in the impedance. The more sophisticated layout packages can add serpentine sections to the traces to keep the lengths the same, and will keep track of the phase variation caused by differences in trace length. Figure 6 is a zoomed-in example of a serpentine trace to equalize line lengths. I did this in Proteus software, and deliberately made a terrible differential pair in order to demonstrate an exaggerated example of a serpentine trace. The right layout package can compensate for length differences, within reasonable limits, of course.

Figure 6
Example of a serpentine trace for length matching of a differential pair
Figure 6
Example of a serpentine trace for length matching of a differential pair

Depending on the PCB vendor you use, they may be able to make your controlled-impedance traces correct. You lay out the board by calculating the expected trace width, spacing, and dielectric thickness, and specify the impedance of the traces to the vendor. The vendor can then adjust the dielectric thickness and trace widths to make the impedances right. This may make manufacturing easier, since they can select from standard dielectric thicknesses, but not all vendors can do this. 

PCB material: FR4 is the most common PCB dielectric, but for high-frequency operation it may not be the best choice. The dielectric constant of FR4 varies with the resins used to make it, and it is lossier than some other materials. For high-frequency designs, especially at microwave frequencies, a different dielectric such as PTFE (Teflon) or the Rogers RO4000 series might be preferable. Of course, different materials will have different dielectric constants.

Phenolic is still used for PCB dielectric, although I’ve generally used FR4. Phenolic is less expensive, so for high-volume products it can result in significant cost savings. You can also get boards made with a ceramic substrate on a metal base. These are useful for operation in high-temperature environments (think automotive or military) where you need a metal base to dissipate heat. However, there is a large difference in thermal expansion between ceramic and the metal base, so the size of this type of board is limited. I’ve used this material in an under-hood automotive application.

DFM: Most PCB tools will do some extra work for you such as checking for Design for Manufacturing (DFM) compatibility. This includes checks for parts that are too close together (which makes automated assembly difficult), and traces that run too close to pads or to other traces. If DFM and other advanced features are supported, there will be menus to set up things like minimum clearance, minimum trace spacing, and other parameters. Some PCB manufacturers will run their own DFM checks when you upload files for quoting.

Components on both sides: It is possible to shrink a board by putting components on both sides (usually surface-mount parts only). However, it requires extra manufacturing steps and raises the cost. In addition, the layout will still need a number of vias, and these can limit how small the board can be. Putting parts on both sides can reduce the overall size, but only by so much.

Turnkey: Sometimes you need a turnkey printed circuit board assembly (PCBA). This is where the board vendor fabricates the blank PCB (or has a PCB fab company do it), orders components to assemble it, populates the board, and, depending on what you are willing to pay for, even does electrical tests. You send them the appropriate files and get back finished boards. The vendor will need additional information to do this such as the bill of materials (BOM) for the board, maybe an assembly drawing, and pick-and-place files for the automated insertion equipment. For home projects, I never purchase turnkey boards. In the corporate world, I rarely did anything else. 

Conclusion: 

Although creating a PCB for a project or a product requires several steps and attention to detail, using modern processes and tools increases the likelihood that your circuit will work the first time. In addition, automated rule-checking and standardized files make it easier to avoid errors that would show up in manufacturing and decrease the yield of the completed assemblies. 

REFERENCES
[1] Digikey trace width calculator: https://www.digikey.com/en/resources/conversion-calculators/conversion-calculator-pcb-trace-width
[2] Sierra via current calculator: https://www.protoexpress.com/tools/via-current-capacity-temperature-rise-calculator/
[3] Sierra Circuits article on striplines and microstrips: https://www.protoexpress.com/blog/difference-between-microstrip-stripline-pcb/
[4] Microstrip impedance calculator: https://www.eeweb.com/tools/microstrip/
[5] Differential trace impedance calculator: https://www.eeweb.com/tools/edge-coupled-microstrip-impedance/

— ADVERTISMENT—

Advertise Here

RESOURCES
Altium: www.altium.com
KiCad: www.kicad.org
Labcenter Electronics: www.labcenter.com
Orcad: www.orcad.com
Siemens: www.siemens.com

PUBLISHED IN CIRCUIT CELLAR MAGAZINE • FEBRUARY 2023 #391 – Get a PDF of the issue

Keep up-to-date with our FREE Weekly Newsletter!

Don't miss out on upcoming issues of Circuit Cellar.


Note: We’ve made the Dec 2022 issue of Circuit Cellar available as a free sample issue. In it, you’ll find a rich variety of the kinds of articles and information that exemplify a typical issue of the current magazine.

Would you like to write for Circuit Cellar? We are always accepting articles/posts from the technical community. Get in touch with us and let's discuss your ideas.

Sponsor this Article
+ posts

Stuart Ball recently retired from a 40+ year career as an electrical engineer and engineering manager.  His most recent position was as a Principal Engineer at Seagate Technologies.

Supporting Companies

Upcoming Events


Copyright © KCK Media Corp.
All Rights Reserved

Copyright © 2024 KCK Media Corp.

Getting Started—PCBs

by Stuart Ball time to read: 14 min