Creating Gerber Files in EAGLE
Creating Gerber Files in EAGLE
In this post, I’ll be using the gerber viewer found here (just download the latest version of the executable), and the information here is based on our use of PCBFabExpress. For this post, I feel like the video is much clearer in explaining the CAM Processor, as the actual text becomes very wordy in trying to describe the steps you need to take to produce your gerbers.
Gerber Files – What are they?
Gerber files contain information that board houses use to control their machinery to manufacture PCBs. With so many different layout programs, gerbers act as a bridge between designer and manufacturer. The most common format in use today is RS-274-X, but you should check with the board manufacturer that you’ll be using to ensure that you use the right format in your boards.
Using the CAM Processor
To create gerbers in EAGLE open your finished board, then click File -> CAM Processor. In the CAM Processor window, you’ll need to create one section for each gerber file that needs to be created. For a two layer board with silk screen and solder mask on both sides, you’ll create seven sections. The section name and prompt have no effect on the output, so put a descriptive name in the section box. The checkboxes in Style should be correct (pos. coord, optimize, and fill pads should be checked), and both the x and y offsets should be set to zero.
The table below shows what device, file extension, and layers need to be selected for each section. To make the file name dynamic, I use the variables that you can look up in EAGLE’s help. Specifically, I use %P to get the path of the board and %N to get the name (without the extension) of the board. So, in my file section, I entered %P\Gerbers\%N.extension, where extension is the extension for the particular section. This lets me use the same processor job for any board I need gerbers for, and all I need to do is create the gerbers directory.

To create the first section, enter CMP in the section name, %P\Gerbers\%N.cmp for the file, select GERBER_RS274X as the device, and select Top, Pads, and Vias in the layer box. Click Add, and it will duplicate this section. Repeat the process until you’ve created all the sections in the table above. Once you’ve created all of the sections, click process job (make sure you’ve created the Gerbers folder in the same directory as your board file) and EAGLE will create all the gerber files you need.
Viewing the Gerbers
Once you’ve created your gerbers, you should always use a gerber viewer to ensure they were processed correctly. An error in version 5.1.0 caused some errors in this particular board that, if we hadn’t checked, would have made our boards unusable if they had been manufactured with those errors. If you’ve installed the gerber viewer I linked at the beginning of this post, open it up, click on the folder icon, navigate to your gerber files, select them all and click open. This will show you what the board house is going to see when they manufacture your PCBs. If everything looks correct, zip your files up and send them to your board house to be manufactured.
One important thing to note (and another reason to check your files) is that all text will be converted to a vector format. If your text is in any other format, it may be stretched or skewed. If you use vector based text, your text should look the same in your gerbers as it does on your board.
Now that we’ve covered the basics from start to finish, I’ll spend the next few posts going into more detail on a few things I’ve touched on in the past. As always, contact me with any questions or suggestions.
Comments
Comment from Juan Villa
Time November 9, 2008 at 2:43 pm
Thank you for an excellent screen cast!
Comment from eric
Time May 5, 2009 at 6:58 pm
i can´t see the video in full screen……
Comment from Lumag
Time September 16, 2009 at 6:47 am
Just one note: for some gerber processors, you should mirror bottom layers, IIUC.
Comment from jorge
Time October 8, 2009 at 2:58 pm
When i try to print the PCB diagram from the Gerber viewer it doesnt print it? please help
Comment from Joshua
Time October 9, 2009 at 5:17 am
I haven’t ever attempted to print the PCB diagram from the Gerber viewer but talking to others who have been able to do so successfully told me that the copper layout was not to scale. I would strongly suggest printing directly from Eagle, especially if you’re using the print-out for your own homemade boards.
At 1:1, Eagle prints the exact size that you’re board will be, great for making sure your part sizes are correct before paying the board house. Simply change the visible layers to show only what you want. Then print!
Let me know if you need more information.
Comment from Jorge
Time October 11, 2009 at 8:23 am
Thanks it really helped.
Since this is my first time using this program what is the recommendation for the size of drills and holes, or does that just depend on me.
Comment from Ryan
Time October 20, 2010 at 11:00 am
The video was very helpful and appreciated. However, when I downloaded the gerber viewer you linked it wouldn’t open the gerber files. They don’t even show up when the program is looking for “GerbV Projects”. Once I change to look for all files they appear, but when I try to open one I get the following error: “could not read C:\Documents\eagle\test\gerbers\test.cmp[-1]“
Comment from Patrick
Time April 4, 2011 at 2:11 pm
Thanks! It really helped me.
Comment from Graham Gillett
Time October 26, 2008 at 4:58 am
Only one article on the web with such an explanatory view of creating these gerbers.