How can 2 GBR files for a single layer be merged into 1 file?

I hope this is the right place to ask these questions. It is not really a project but I did not see where else it might fit. I have a set of GBR files that was created 15 years ago by some pcb product of the time. The designer did not make a top solder mask file. The top layer of the 2 layer board was split into 2 separate GBR files. As you might guess, the board houses will not even talk to me about merging the 2 files to make up that top layer. One file is the ground.gbr because the top is “mostly” ground plane but does have a a couple runs not tied to ground. Anyway there is a separate GBR file for the non ground portion. Since I do not have a schematic file and no project file. Is it possible to merge those 2 files to make the top layer? How can that be done?

Second, is there any way to also create a top solder mask file without having that file already?
Thank you for your help.

So you are saying that the front Cu was split into two files, is that right?

Gerber panelizers have to merge Cu layers from multiple Cu files, offsetting them to position in the result. If you could look at the source code of one you might work out what’s being done. It may be as simple as concatenate the preambles, then concatenate the bodies.

The first panelizer that came up in a search for open source tools is: GitHub - halfmarble/hm-panelizer: a simple PCB panelizer I know of one other but that’s written in C# which is just as bad as Java IMO.

Good luck and let us know how you go.

What happens if you open the two files in the Gerber viewer? are they correct aligned and the same scale?

With KiCad’s Gerber viewer you can back-export gerbers to a KiCad PCB, and during the export you can choose on which layer to put the Gerber info.

When you have created a PCB from your Gerber files, you can change the layer of items.

This will of course not create a full PCB, because there are no real footprints in gerber files, it’s only pads and flash codes. There is also no real netlist yet, but it can be re-created because the netlist is implied in the placement of the copper tracks.

Some time ago I made a tutorial for:

Yes the top copper layer was split into 2 separate gerber files. Board houses have no clue what to do with that and are requiring me to send them one gerber file for that top component layer. I did not think that was panelizing since it is the same single board. I know I can load both gerbers into Kicad but it shows them as 2 separate layers and no way that I can merge them (that I know of).

Thank you.

When both files are loaded into Kicad they are shown correctly and are aligned but as I have said, Kicad considers it to be 2 separate layers rather than 1 layer and I need it to be one file for that layer instead of the current 2 files.

Thank you.

What I’m saying is that the process of panelising Gerbers involves combining corresponding layers into a single file for each layer, but offsetting each board. If you make the offset 0,0, that’s effectively combining the two layers.

Just try a quick experiment, concatenate the two F.Cu files and see if it displays correctly in a viewer. Maybe it won’t work, but it’s a cheap experiment.

Gerber is a text format file that controls a photo plotter. So long as none of the two plots copper actually touch, you should be able to cut and paste control sections from one file to the other.

This can be done, as I already explained in the tutorial inked above.
In short, the workflow is:

  1. Load all gerber files in Gerbview.
  2. Export all layers into a PCB project.
  3. In the PCB Editor you can move or copy stuff between layers.
  4. Generate Gerbers again.

There are also editors that can directly edit gerber files, but such a program is not a part of the KiCad project.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.