Do you want the sample script which uses the Automatio Pro?
PDF Files? You mean Assembly Drawings?
What you are asking is not a trivial task. It is also not a 'one size fits all' kind of thing. There are several reasons for this:
- There is usually a company naming convention for output files that needs to be included in this kind of script.
- Some remove unused pads, some don't. This is part of Gerber Setup. Lots of other company specific rules about Gerber Setup.
- There are often user layers that are included in Gerber output. How to know which ones?
- Not all companies include the same output files in what they create/store/send to vendors.
- The way the files get collected and stored in the database file structure is probably unique.
- And so on . . .
Having said that, I can assure you that it is possible to do all the things you asked, and meet all the company specific requirements for what to output, how to name the files, and where to put them. A lot of it is done by writing out the Gerber/Drill setup files in the Config directory, then executing the output commands programmatically. In a lot of cases it's only a question of executing the command via a script. Getting the syntax right for creating those config files is a bit tricky. From there, it is a lot of File I/O operations to create directories, copy/move files, rename them etc.
The Gui.ProcessCommand function is very useful. It is what you use to execute commands via scripts. Here is an example that writes out Gerber data: (VB6)
Private Sub write_gerber()
Dim gui As gui
Dim dlg As Dialog
Dim btn As button
Set gui = app.gui
gui.SuppressTrivialDialogs = True
If gui.ProcessCommand("Output->Gerber", True) Then
Set dlg = gui.FindDialog("Gerber Output")
If dlg.IsValid() Then
Set btn = dlg.FindButton("Process Checked Output Files")
If btn.IsValid Then
'MsgBox ("Found Process Checked Output Files button")
MsgBox ("The Process Checked Output Files button was not found.")
Set btn = dlg.FindButton("Close")
MsgBox ("The Gerber Output Dialog box was not found.")
MsgBox ("The Output Gerber Command was not found. Try restarting the Application.")
MsgBox ("Gerber Data is in the /Output/Gerber directory.")
I hope this gets you going on the right path.