HOW TO ACCURATELY PRINT GERBER FILES AT HOME
Gerber files, the industry standard format for photoplotting in the electronics industry, are ASCII text files used to represent Printed Circuit Board (PCB) layout patterns. Typically your EDA package (KiCad, EaglePCB, Altium Designer, etc) will produce these files when you need to have a PCB made professionally by a PCB fabrication house, for example, PCBWay, PCB-POOL, etc. As an electronics engineer you are familiar with Gerber files to the extent that you would create them and then check them with a Gerber viewer. For a very long time, CAMTastic has been bundled with Altium products as far back as the late 1990s. I have used CAMTastic, and GCPREVUE/GCPowerStation for a long, long time.
Now, in 2023...
Since I am now developing products to disrupt the industry a little bit- products that enable makers to produce reasonably professional PCBs at home or the office, I have had to relearn everything there is to know about Gerber file formats, but more specifically, something I have never done before at home- the editing of multiple jobs onto a single film set, and the printing of same. The former is not something new, but the latter has been a real challenge for me. Nonetheless I have solved the problems and the PCB manufacturing can commence.
Let's go back in time, again...
In the 1990s, when I began my career, it was possible to have your Gerber files imageset to film as a film negative at companies that offered repro and typesetting services. In my country, these companies no longer exist at all, and nobody is able to assist me with this. The reason: everything has gone the way of "direct-to-plate". Indeed, even with silkscreening, these days silkscreen negatives are being done on what one could consider low resolution equipment- consumer inkjet printers. The last time I had a film negative made was in 1996. The company that produced that negative for me no longer exists.
I stopped with the film negatives in 1996 because Positiv 20 was just so much easier to get and to use than dry film photoresist, and because I had access to HP LaserJet 4 printers at work that were capable of printing completely opaque onto transparency film, it was stupidly easy to make a very decent PC board with minimal effort using the sun for exposure.
Now, in 2023...
Since I am now developing products to disrupt the industry a little bit- products that enable makers to produce reasonably professional PCBs at home or the office, I have had to relearn everything there is to know about Gerber file formats, but more specifically, something I have never done before at home- the editing of multiple jobs onto a single film set, and the printing of same. The former is not something new, but the latter has been a real challenge for me. Nonetheless I have solved the problems and the PCB manufacturing can commence.
Let's go back in time, again...
In the 1990s, when I began my career, it was possible to have your Gerber files imageset to film as a film negative at companies that offered repro and typesetting services. In my country, these companies no longer exist at all, and nobody is able to assist me with this. The reason: everything has gone the way of "direct-to-plate". Indeed, even with silkscreening, these days silkscreen negatives are being done on what one could consider low resolution equipment- consumer inkjet printers. The last time I had a film negative made was in 1996. The company that produced that negative for me no longer exists.
I stopped with the film negatives in 1996 because Positiv 20 was just so much easier to get and to use than dry film photoresist, and because I had access to HP LaserJet 4 printers at work that were capable of printing completely opaque onto transparency film, it was stupidly easy to make a very decent PC board with minimal effort using the sun for exposure.
The best printer ever made, nothing has been able to touch it, until, EPSON released the L3110
Unfortunately, that employment came to an end in late 1999 (it is referenced in the yearbook as the trigger event that led to my current path), and by leaving that company, I no longer had any access to the HP printers. Sadly, no other printer has been able to print quite as well as the HP Laserjet 4, and, I simply wasted my money in 2001 buying a HP LaserJet 5L to try and replicate past success.
From back then, to now...
So from 2001, with access to the industry via my first electronic engineer job, I never bothered much with making PCBs with precision again. Most of the time I would simply make a quick prototype at home on the odd occasion, but when I was serious about a project, I would simply use the local PCB manufacturer. I have done so for many years, and I have a nice collection now of boards I have designed over the years for projects at home, created with Protel 99SE all the way through to Altium Designer.
During the past three or so years, the costs of having PCBs made locally have become prohibitive. Although PCBWay and others have good pricing in spite of the shocking exchange rate, the shipping to my country still makes it a no-go. So I began to think about how to do this myself and with reasonable accuracy, for example, a common value of 0.2mm feature size. In 2023 I decided to invest heavily in equipment to roll my own PCBs at home, and this guide is some of the results of that work. Other articles will cover other aspects of my foray into PCB manufacturing.
The fundamental imaging problem
The first problem to solve was how to be able to make film negatives. We had earlier purchased an EPSON L3110 Ink-Tank printer with the intention of printing in colour especially in volume for our son's school projects. My first experiments with this printer revealed the fact that the EPSON supplied black ink, is extremely opaque to UV light in the 250-260nm range. This means that even if the dark areas in the transparency don't look completely black, trust me, UV-A light is blocked completely.
This was an exciting discovery. In addition, the printer was also found to be able to be set into a mode where it would print extremely accurately, typically taking as long as 15-20 minutes to print an A-4 page, and with ink so tightly packed on the transparency film, it would be raised, like a shitty tattoo, and just the way I remember the HP Laserjet 4 used to pack toner onto transparency film. So I was set, or so I thought.
I would then discover that, getting a Gerber file to be rendered accurately into a PDF I could then print on the printer would be a major challenge. In the past I would simply use any one of the available PDF printers (such as Microsoft Print to PDF) and print directly from Altium Designer. That works if you're doing single PCBs. However, when I transitioned to using dry film photoresist, and began to set up the process whereby multiple boards could be added to a single PCB sheet, I ran into problems.
What I have found is that the two Gerber editors (CAMTastic and GCPowerStation) I have access to, are not able to render highly accurate PDF files or generate negatives of the Gerber layers. The latter is a major pain. Initially I thought I could remedy this using the Swiss-army-knife known as CorelDRAW, but, that's when I discovered that CorelDRAW is at best, accurate to 0.2mm and the errors accumulate rather quickly the moment you start moving stuff around or snapping to guides and don't make sure the objects snap by edge. Also, when exporting stuff to CorelDRAW friendly formats such as EPS and DXF, weird stuff begins to happen.
So let's look at the problems I've faced trying to get to a workable solution:
GCPrevue/GCPowerStation
Using the Microsoft to PDF printer, you can clearly see the resulting PDF is just garbage. The line ends are tacky and the hollow shapes in the text are all filled in.
From back then, to now...
So from 2001, with access to the industry via my first electronic engineer job, I never bothered much with making PCBs with precision again. Most of the time I would simply make a quick prototype at home on the odd occasion, but when I was serious about a project, I would simply use the local PCB manufacturer. I have done so for many years, and I have a nice collection now of boards I have designed over the years for projects at home, created with Protel 99SE all the way through to Altium Designer.
During the past three or so years, the costs of having PCBs made locally have become prohibitive. Although PCBWay and others have good pricing in spite of the shocking exchange rate, the shipping to my country still makes it a no-go. So I began to think about how to do this myself and with reasonable accuracy, for example, a common value of 0.2mm feature size. In 2023 I decided to invest heavily in equipment to roll my own PCBs at home, and this guide is some of the results of that work. Other articles will cover other aspects of my foray into PCB manufacturing.
The fundamental imaging problem
The first problem to solve was how to be able to make film negatives. We had earlier purchased an EPSON L3110 Ink-Tank printer with the intention of printing in colour especially in volume for our son's school projects. My first experiments with this printer revealed the fact that the EPSON supplied black ink, is extremely opaque to UV light in the 250-260nm range. This means that even if the dark areas in the transparency don't look completely black, trust me, UV-A light is blocked completely.
This was an exciting discovery. In addition, the printer was also found to be able to be set into a mode where it would print extremely accurately, typically taking as long as 15-20 minutes to print an A-4 page, and with ink so tightly packed on the transparency film, it would be raised, like a shitty tattoo, and just the way I remember the HP Laserjet 4 used to pack toner onto transparency film. So I was set, or so I thought.
I would then discover that, getting a Gerber file to be rendered accurately into a PDF I could then print on the printer would be a major challenge. In the past I would simply use any one of the available PDF printers (such as Microsoft Print to PDF) and print directly from Altium Designer. That works if you're doing single PCBs. However, when I transitioned to using dry film photoresist, and began to set up the process whereby multiple boards could be added to a single PCB sheet, I ran into problems.
What I have found is that the two Gerber editors (CAMTastic and GCPowerStation) I have access to, are not able to render highly accurate PDF files or generate negatives of the Gerber layers. The latter is a major pain. Initially I thought I could remedy this using the Swiss-army-knife known as CorelDRAW, but, that's when I discovered that CorelDRAW is at best, accurate to 0.2mm and the errors accumulate rather quickly the moment you start moving stuff around or snapping to guides and don't make sure the objects snap by edge. Also, when exporting stuff to CorelDRAW friendly formats such as EPS and DXF, weird stuff begins to happen.
So let's look at the problems I've faced trying to get to a workable solution:
GCPrevue/GCPowerStation
Using the Microsoft to PDF printer, you can clearly see the resulting PDF is just garbage. The line ends are tacky and the hollow shapes in the text are all filled in.
W.T.F.???
GerbV
Use GerbV they said... well I had some interesting experiences with that too, look what it does to my target circles in PDF
Use GerbV they said... well I had some interesting experiences with that too, look what it does to my target circles in PDF
GerbV has an internal shit fit about the circles and then decides to render them as a JPEG embedded in the PDF.
Tried other software
So yes, I tried other software to get this right:
GerbView 10 - Did similar things that GCPowerStation did, the PDF was unusable
Gerber2PDF - Program just crashes, complaining about formatting errors
In the end, one unlikely piece of software succeeded where others failed, and that program is called GerbMagic.
GerbMagic produced a perfect negative in PDF
So yes, I tried other software to get this right:
GerbView 10 - Did similar things that GCPowerStation did, the PDF was unusable
Gerber2PDF - Program just crashes, complaining about formatting errors
In the end, one unlikely piece of software succeeded where others failed, and that program is called GerbMagic.
GerbMagic produced a perfect negative in PDF
That is what it's supposed to look like
And that's it, you now have a PDF you can print directly to your EPSON printer when loading it with 3M CG6000 transparency film!
Then it goes south, but as always, I solve the problem!
After just one day (24 hours), GerbMagic decided it was in "trial mode". Lovely! It won't print or generate PDF. So I went to the website to go have a look at how much they want for a license. I assumed, in the absence of a clear explanation on that website of theirs that looks like it was made in 1996 that the software was trialware.
I was utterly shocked. It is very clear that they are living in 1995 with the Motorola mindset. WHO THE HELL PAYS $439 for a piece of software to convert Gerber to PDF??? I am sorry but a program like that should only cost at most $69.
Work that back into my local currency it's 3 weeks' pay! Madness! Nope! Not going to pay that! Not even as a company expense claim!
Anyway I decided to look at why GCPowerStation was generating garbage on PostScript. With a fresh set of eyes the next day I decided to play around with the PostScript settings. And now, for reasons I cannot explain, it works. It shipped a beautiful PostScript image at very high DPI to CorelDRAW where a simple "Invert colors" operation and the addition of a background layer in CMYK 0 0 0 255 rendered a beautiful negative indeed. I can only assume Windows was to blame.
I was utterly shocked. It is very clear that they are living in 1995 with the Motorola mindset. WHO THE HELL PAYS $439 for a piece of software to convert Gerber to PDF??? I am sorry but a program like that should only cost at most $69.
Work that back into my local currency it's 3 weeks' pay! Madness! Nope! Not going to pay that! Not even as a company expense claim!
Anyway I decided to look at why GCPowerStation was generating garbage on PostScript. With a fresh set of eyes the next day I decided to play around with the PostScript settings. And now, for reasons I cannot explain, it works. It shipped a beautiful PostScript image at very high DPI to CorelDRAW where a simple "Invert colors" operation and the addition of a background layer in CMYK 0 0 0 255 rendered a beautiful negative indeed. I can only assume Windows was to blame.
Yes! We can put that on film!
At any rate this makes me more comfortable because now I only need a single Gerber editor installed on my system and I can do everything in there, and be sure nothing has moved, everything is the right size (and precision) and registers with the Excellon drill data. The chances of mistakes are greatly reduced!