Create GERBERs inside a zip file

One interesting feature in my opinion is a option to compact the gerbers+drill files inside a zip file. And also open direct this zip file on the gerber view.

1 Like

What’s the question here?

Exactly, sorry if it was not clear.

I would find that useful. Fab houses usually want it zipped all together anyways when you send it to them.

Automation of that task sounds like a good feature. Perhaps have it as an option when generating Gerbers?

Yes, I could propose a field to fill if execute at the end as some Linux software have, and than put manually. But this is now compatible with Windows users.

Even a option open the GERBERs when finished the generation will be userful.

1 Like

I don’t know if I would use that “feature” even if it was available. Assembling a handful of files into a ZIP-archive is a very simple task in Windows, or at least it is on my machines. (I don’t recall if I had to do anything special to integrate the Windows File Mangler with 7-zip, or IZArc, or not.)

And there’s a fair amount of variability in the ZIP-files you send off to the board fabricator. There’s typically a “Readme.txt” file included, to provide metadata. And some fabricators want the files named according to a certain pattern, which may not be available in KiCAD. And you may not want to send all of your Gerber files to the board fabricator - some layers may contain assembly data that is used for internal documentation or sent to a contract assembly house, but has no meaning to the board fabricator; the Paste layers may get sent to a different vendor, to get stencils made, etc. I’m afraid that creating a KiCAD menu that could deal with all these possibilities would only lead to confusion among KiCAD users.

Dale

3 Likes

If you have trouble keeping your gerber outputs separate from the remainder of the files in that project folder, may I suggest typing ‘gerbers/’ into the output folder location field?
This is being saved per project.
It’s then very easy to create a zip file from the content of that folder without the other project files getting in the way.

Unfortunately this setting is stored in the kicad_pcb file and not in the pro file, were it would be easy to globally set this once (in the template.pro file) and forget about it.

3 Likes

But one can already select which layers they are going to export within the Gerber export selection anyways. So instead of selecting the directory to dump them in, why not a tickbox that dumps straight into a zip file?

I know it’s not hard to zip a directory, but I thought the point of CAD tools was to make the process faster and more efficient? It’s bad enough that there are so many different output formats for PCBs from different software, and the closest there is to a cross software standard is a zipped folder of Gerbers. I think perhaps embrace that and reduce the effort required by the user in getting to that point. After all, the whole point of the export is to get the files to a fab house, yes?

Though now that I think about it, would a Python script be the way to go for publishing a specific zipped Gerber set for a particular fab house? This wouldn’t interfere with the power users, but still be extremely flexible and then bundled with future versions?

  1. Some fabs want different file endings than KiCAD generates.
  2. any additional txt file also has to go in there manually
  3. if you make different sets of gerber zips (pcb fab, assembly, stencil) you want pre-select gerber layer selections next :wink:

PS: all that being said, this is just a support forum.
If you want it so badly, take it up with the developers on the bugtracker.
As always - if you have a patch ready that does what you want they might be more inclined to put this in as otherwise they already have enough of their own ideas on the plate that demand programming time.
Good luck.

1 Like

No idea if the plotting capacity of PCBnew is exposed via the python scripting API.
Might need to ask the scripting gurus about that.
@HiGreg comes to mind.

Sure, it could be scripted in Python. I use some C# code to package gerbers into a zip file, and also create a project file for gerbv.

If it is just handling files, that is quite easy, but it’s possible to create custom plotting with the pcbnew API. I think OSHPark use such scripts for their service.

2 Likes

There are some exposed GERBER-related plot commands, but I’m not even sure you need them. You could write a post processing script in python to zip the various combinations of files you need. And call it from pcbnew. If you set it up as an ActionScript, it will install itself in a submenu of the Tools menu.

1 Like

Yes, this was my first configuration and after create a zip with the folder.
I just think that create manually a zip is a dummy step, even with you need to rename the files or add a README.txt, you can do in the zip.

I know this is an old post, but i am just now looking for the easiest way to output the zip for the production house and i am wondering if this has been added or if i just haven’t found it.
I am not sure about how consistently useful it would be to open in the gerber viewer since i always use the PCB house viewer as a final check. But the ‘one click’ CAM creation to a production ready zip file is in the commercial package i use and it is extremely useful. Yes, child’s play to do this in windows but the single click is really, really nice feature that helps avoid doing one more repetitive task.

Gerberview already open the ZIP file, but Pcbnew doesn’t generate it yet