Drop us a line through the form below and we'll get back to you within 48 hours to let you know how we can help and answer all your questions.

Let's talk about your project

6th February 2019

A Brief Guide to CAD for Electronic PCBs

Over the last couple of weeks I’ve had some conversations highlighting a level of mystery surrounding CAD (Computer Aided Design) tools and their manufacturing outputs. To help clear this up, here is a brief guide to the general process flow and files encountered within CAD for electronic printed circuit boards (PCBs).

Schematic

The schematic is generally the starting point for capturing the design of electronics. This may be generated before, during, or after some prototyping and simulation depending upon the complexity of the design and the tools used.

The schematic drives the connectivity of the printed circuit board. Each device placed on the schematic is represented by a symbol that has several connection points or pins. The symbols used adhere to general conventions where capacitors are shown as two parallel lines, resistors as a jagged line, inductors as a straight coil etc.

For integrated circuits (ICs), the simple devices may be shown as a single rectangular part with pin number and pin names. More complex ICs may be broken up into sub-symbols for clarity. Schematic symbols don’t need to be ordered numerically. They are more frequently seen ordered logically with functional groups of pins together.

Neat & Tidy

The schematics will be referred to repeatedly throughout the development and production life of the product. They should be neat, have components grouped into circuit elements and have a logical structure to them.

Often schematics are split into multiple pages, each with a functional area. It may also have notes on and additional attributes added for PCB layout (impedance, width, current etc) and to assist the firmware developers with default pin configurations and boot order.

Look out for messy schematics as these can be tell tales of sloppy work continuing into the PCB design itself. Schematics where the purpose of the circuitry isn’t clear are red flags. Some designs deliberately obfuscate the functionality to make themselves indispensable. This helps no-one as it slows debug, makes compliance more difficult and leads to errors when the product is updated for obsolete components.

The schematic will have numerous components on, many of the same type. Each component will be annotated with a reference designator such as R1, R2, or IC75 to give them a unique reference on the printed circuit board. This reference is used later when the components are being fitted or placed on the printed circuit board.

The main outputs from the schematic stage of the project are:

Libraries

The symbols used to represent components on a schematic have associated printed circuit board footprints with them. These footprints are shapes with definitions for the copper patterns, holes, solder paste, solder mask, and silkscreen for printed circuit board markings. Increasingly, the footprints also have a 3D model associated with them.

It is these footprints that appear on the printed circuit board’s outer copper layers and that the components are soldered to.

Netlist

The netlist is a file that contains the connections between each component. The image below shows when this is brought into the PCB layout, with each of the component physical footprints connected with thin lines.

There is also an area, in this case a black rectangle, that represents the printed circuit board area. When first imported the components are placed to the side of the printed circuit board area.

The printed circuit board layout can begin in a number of ways:

  • If the enclosure details are known in advance, the PCB area shape is adjusted to fit the enclosure together with mounting holes. This keeps out areas to avoid clash with mechanical objects. Connectors, batteries, buttons and displays are likely to have fixed positions too.
  • If the enclosure isn’t defined, then the PCB designer may have a little more freedom. Although they are likely to get the helpful guidance of “making it as small as possible”. In this case the designer may wait to define the size and shape of the board until later.

The board construction, including number of and separation of layers, will be setup to meet various constraints from the schematic. Then the components will be placed and connected (routed).

Most CAD tools allow a component to be highlighted in the schematic part of the tool, and for the corresponding footprint to be highlighted in the PCB part. This allows functional groups of components to be placed appropriately. PCB layout is key to ensuring designs work properly. It is not enough to just connect them together on the board.

Once any issues from Design Rule Checking have been addressed the two main outputs from the PCB tools are:

  • Board artwork files (Gerber and drill files)
  • Pick and place file (also known as centroid file or x-y data)

Design Rule Checking (DRC)

The completed printed circuit board should then have design rule checks performed. It is perfectly possible to skip this step and to output manufacturing files. It’s worthwhile checking that the designer has run DRC and that it passes.

Other design rules to check include:

  • each of the connections have been routed in copper
  • there are no short circuits
  • the tracks are at least the minimum width
  • tracks are a minimum distance from the board edge
  • tracks and components are at least the minimum clearance from each other
  • component pads are free from silkscreen (board markings)
  • other custom rules such as width for high current and length matching for serial busses

Bill of Materials (BoM)

The bill of materials output from the schematic details the exact part number and manufacturer of each part against the reference designator. Every single letter and number of the part number is important as they specify component size, value, voltage rating, packaging and more.

It is common practise to simply list the catalogue numbers from the major component distributors such as Digikey, Farnell, and Mouser. This can lead to issues as manufacturers can be free to supply similar parts under a generic code for connectors or to reuse the code years later. It can also lead the Contract Electronics Manufacturer (CEM) that fits the parts to the board, to use the catalogue source instead of purchasing from the best commercial supplier.

It’s much safer to use the part number from the manufacturer in the Bill of Materials.

Gerbers and drill files

The printed circuit board data is reduced to simple plots of the printed circuit board copper layers, the drill sizes and locations and the apertures for solder and paste masks.

PCB manufacturers use the Gerber files together with notes from the layer stack on required impedances and tweak them for their manufacturing processes. This is to ensure the copper tracks are etched correctly.

File extensions are used to identify the various types of Gerber file output. The common extensions are:

File extension

Description
gtl Top Copper
gbl Bottom Copper
gts Top Soldermask
gbs Bottom Soldermask
gto Top Silkscreen
gbo Bottom Silkscreen
drl NC Drill

 

Can Gerber files be modified?

A question I’m often asked is can we edit the Gerber files because the original schematic and PCB files are either lost, corrupt, drawn in an obsolete tool or similar?  The simple answer to this is that yes. It is possible to edit the Gerber files, but unless the change is very small such as thickening a track or removing a short circuit connection, it then becomes very risky.

Gerbers are made up of primitive shapes and positions. There is little to no knowledge of the schematic connectivity from the netlist. This means that it is very easy to make a mistake when editing the board and to have no way of checking it. This is because there is no schematic connectivity to check against.

Edits to printed circuit boards are best performed by following the CAD toolchain flow:

  • Making the changes to the schematic,
  • generating the netlist,
  • importing the netlist,
  • updating the pcb,
  • error checking the pcb,
  • and outputting Gerber files.

Pick and place data

Pick and place data, together with the Bill of Materials, tells the Contract Electronics Manufacturer (CEM) which components to fit, the orientation and the X-Y location on the PCB. The components are not placed on the pads of the PCB footprint but instead are placed at the x-y coordinates where the component footprint is.

If you would like to talk about this in more detail, complete our Contact Form, or give us a call on 0115 772 2825.