What is a Gerber File?
A Gerber file, also known as a Gerber-PCB file, is a standard file format used in the design and manufacture of printed circuit boards (PCBs). It contains all the necessary information to describe the PCB layout, including the copper traces, solder mask, silkscreen, and drills.
Gerber files were originally developed by the Gerber Systems Corp. in the 1960s for their vector photo plotters. Over time, it became the de facto standard file format for the PCB industry and is now used universally for PCB fabrication data.
Gerber File Format
The Gerber file format is an ASCII vector format where data is represented by X,Y coordinates and drawing commands (called D-codes). Each Gerber file corresponds to a single layer of the PCB – for example, the top copper layer, bottom copper layer, solder mask, etc.
Here is an example of what Gerber file data looks like:
G04 Gerber RS-274X*
%FSLAX24Y24*%
%MOMM*%
%ADD10C,0.2540*%
D10*
X1000Y1000D02*
X1500Y1500D01*
X1000D02*
M02*
This Gerber data defines the start and end coordinates of a line segment (a copper trace) that is 0.254mm wide.
While Gerber files may look cryptic, they provide a very precise and efficient way to describe PCB geometry in a format that can be universally understood by PCB design software and manufacturing equipment.
Role of Gerber Files in PCB Design
PCB Design Workflow
The PCB design process typically follows these steps:
- Schematic capture – creating the circuit diagram
- PCB layout – arranging and routing components on the board
- Design rule checks (DRC) – verifying the layout meets manufacturing constraints
- Gerber file generation – exporting Gerber files for each PCB layer
- Gerber file validation – checking Gerber data is correct before manufacturing
So Gerber file generation is one of the key outputs of the PCB design process. The PCB designer will use their EDA (electronic design automation) software to export a set of Gerber files that fully describes their board ready for fabrication.
What Gerber Files are Needed to Manufacture a PCB?
A typical 2-layer PCB will require the following Gerber files:
Gerber File | Layer |
---|---|
.GTL | Top (outer) copper |
.GBL | Bottom copper |
.GTS | Top solder mask |
.GBS | Bottom solder mask |
.GTO | Top silkscreen (overlay) |
.GBO | Bottom silkscreen |
.TXT | Drill (hole) data |
Additional files may be needed for more complex PCBs with inner layers, solder paste layers, etc. The key is that the complete set of Gerber files must fully define the PCB layer stackup and all the elements to be printed or drilled on each layer.
Role of Gerber Files in PCB Manufacturing
Once the Gerber files have been generated by the PCB designer, they are sent to the PCB fabrication house for manufacturing. The fab house will use the Gerber data throughout the manufacturing process:
CAM (Computer Aided Manufacturing)
The first step is to import the Gerber files into the fab house’s CAM software. This software will:
- Check and validate the Gerber data
- Assign the Gerber files to the appropriate layers and processes
- Add tooling/alignment holes and other fab house elements
- Generate coordinates and commands for the manufacturing machines
So the CAM process takes the designer’s Gerber files and prepares the optimized manufacturing data needed to actually build the PCB.
Exposing Photo Tools
The first manufacturing step is to create a set of photo tools (film or glass plates) for each of the PCB layers. This is done by loading the Gerber data into a laser photoplotter.
The photoplotter exposes the image of each layer onto the film or glass plate by precisely moving the laser beam according to the coordinates and apertures defined in the Gerber file. Where the laser strikes, it hardens a photosensitive emulsion on the film creating the image of that PCB layer.
The resulting set of photo tools will be used to image the PCB layer patterns onto the copper clad laminates in subsequent steps. The accuracy and resolution of the photo tools is critical as it determines the minimum feature sizes and quality of the finished PCB.
Imaging and Etching PCB Layers
To build up the layer stackup of the PCB, the fabricator will use the photo tools to image the Gerber file patterns onto the copper laminates:
- The laminate is coated with a light-sensitive film called photoresist
- The photo tool is placed on top of the photoresist
- UV light is used to expose and harden the photoresist that is not covered by the opaque areas of the photo tool
- The unexposed areas of photoresist are chemically removed leaving the copper exposed
- The exposed copper is etched away using an alkaline or acidic solution
- The remaining photoresist is stripped off leaving the copper pattern defined by the Gerber file
This photolithography and etching process is repeated to create each of the copper layers of the PCB according to their respective Gerber files.
Solder Mask and Silkscreen
The solder mask and silkscreen layers are imaged in a similar way to the copper layers. The respective Gerber files are used to create photo tools which are used to print the solder mask and silkscreen inks onto the outer layers of the PCB.
The solder mask ink is applied and then exposed and developed using the solder mask photo tools such that ink remains only in the areas between the copper pads and tracks. This electrically insulates the copper and protects it from oxidation.
The silkscreen ink is then printed on top of the solder mask to add text and component identifiers to the PCB as specified by the silkscreen Gerber files.
Drilling and Routing
The final steps are to drill the holes and cut out the individual PCBs from the panel:
- The Gerber drill file (.TXT) is loaded into a CNC drilling machine which drills all the holes (vias and component holes) into the PCB
- A routing machine or V-scoring machine is used to route or score the individual PCB outlines based on coordinates in the Gerber files
After final inspection and testing, the completed PCBs are packaged and shipped to the customer. The PCBs are now ready for assembly!
Advantages of Using Gerber Files
There are many advantages to using Gerber files for PCB design and manufacturing:
-
Universality – Gerber is the most widely used data format for PCB fabrication. Virtually every PCB design software can export Gerber files and every PCB manufacturer can accept them.
-
Simplicity – Gerber files are simple ASCII text files that can be viewed and edited in any text editor. This makes them human-readable and easy to debug compared to binary formats.
-
Precision – Gerber files can describe PCB features and locations down to sub-micron precision. This allows very high density and high resolution PCB designs to be fabricated.
-
Reliability – Gerber files contain all the information needed to reliably manufacture the PCB. As long as the Gerber files are correctly generated, the PCB fab house has everything they need to make the board with no ambiguity.
-
Portability – Since Gerber files are self-contained and universal, PCB designs can be easily transferred between different design tools and manufacturers without loss of fidelity. The same Gerber files can be sent to multiple fab houses for quotes or second-sourcing.
These factors have lead to Gerber becoming the backbone of the PCB design and manufacturing process. By standardizing and simplifying the data exchange between designer and manufacturer, Gerber files enable an efficient, reliable and Transparent PCB fabrication workflow.
Frequently Asked Questions
1. What software can I use to view Gerber files?
There are many free Gerber viewer programs available including:
- Gerbv
- ViewMate
- KiCad GerbView
- Tracespace
Most PCB design tools like Altium, Eagle, KiCad, etc. also have built-in Gerber file viewing and generation capabilities.
2. What resolution should I use for Gerber files?
The standard resolution for Gerber files in the PCB industry is 2.4 format which provides a resolution of 1/100,000th of an inch (0.254 microns). This is suitable for most PCB designs.
For high-density PCBs with very fine features, you may need to use higher resolutions like 2.5 format (0.127 microns) or 2.6 format (0.0635 microns). However, not all PCB fab houses support these higher resolutions so it’s best to check with your manufacturer first.
3. How do I check my Gerber files are correct?
Most PCB design tools have built-in Gerber file validation features that will check your exported Gerber data for common errors. You can also use free online Gerber file checkers like:
- PCBWay Gerber Viewer
- Dirty PCBs Gerber Checker
- Eurocircuits PCB Visualizer
These will load your Gerber files and highlight any issues or discrepancies for you to correct before submitting them for manufacturing.
4. What if I don’t want to use Gerber files?
While Gerber is the most common PCB fabrication format, there are some alternatives you can use:
- ODB++ (Open Database++)
- IPC-2581
- DXF (Drawing Interchange Format)
These formats can contain more information than Gerber (like netlist data) and allow bi-directional data exchange between design and manufacturing. However, they are not as widely supported as Gerber so you may be limiting your choice of manufacturers.
5. Do I need to send anything else to the PCB fab house besides Gerber files?
In addition to the Gerber files, you should also send the following to your PCB fab house:
- NC drill files – These contain the locations and sizes of all the drilled holes
- Fabrication drawing – This shows the dimensions, layer stackup, materials and any special instructions for the PCB
- BOM (Bill of Materials) – List of parts used on the PCB along with quantities and reference designators
- Centroid file – XY coordinates of the center of each component on the PCB (used for automated assembly)
The fab house will use these files along with the Gerber data to fully define your PCB and how it should be manufactured and assembled. The more complete and accurate information you can provide, the better!
Conclusion
In conclusion, Gerber files play a critical role in the PCB design and manufacturing process. They provide a universal, precise and reliable way to describe the complex geometries and layer structure of a PCB in a format that can be used by any PCB fab house.
By understanding how Gerber files are generated and used, PCB designers can ensure their designs are successfully and consistently manufactured. And by standardizing on the Gerber format, the PCB industry can streamline the data exchange between design and fabrication, enabling an efficient and robust manufacturing workflow.
So while Gerber files may seem like just another output of the PCB design software, they are in fact the essential link that brings a PCB design to life as a physical, manufactured product. From photo tools to etching and drilling, Gerber files are the digital DNA of every PCB!
Leave a Reply