Using ConfigPost’s File Handling Features
PartMaker can create more than one output file and/or combine output files. This function is very useful when working with dual path controls and/or creating tool lists, for example.
When you want to split a file, the first four lines of the post processor must be as follows:
#define MACHINE NAME<eob>
#split<prog-name>.TXT FILE1.EXT FILE2.EXT OUT_NAME.TXT<eob>
#merge MERGEFILE.EXT FILE1.EXT FILE2.EXT<eob>
#remove FILE1.EXT FILE2.EXT<eob>
The four lines shown above must be placed in the File Start section of your Post file.
MACHINE NAME
can be any name that you choose.Note: At this time,MACHINE NAME
is not used.
The #split
command instructs PartMaker to take the initial output file <PROG-NAME>.TXT
and split it into as many files as are defined by the arguments that follow.
Unlike basic PartMaker applications, this <PROG-NAME>.txt
will not be the final G-code program that you send to the CNC. <PROG-NAME>.txt
will be split into the number of additional files you have designated, as shown in the following illustration.
Each argument, separated by a blank space, represents a valid file name that will be created during post processing. The names may be user-defined, without path statements; the only required name is OUT_NAME.TXT
as described later in this section.
<prog-name>.TXT
is the name of the file initially created by ConfigPost as entered by the user.<prog-name>.TXT
is a text file.FILE1.EXT
is the first file to be created from the split. This file may have any legal file name (such asFILENAME.TXT
orNAME.XXX
(it does not have to be a .TXT extension).FILE2.EXT
is the second file to be created from the split. As withFILE1.EXT
, the file name does not require a .TXT extension.OUT_NAME.TXT
is a special file name that must be created any time the split/merge function is used. Note: Information written to theOUT_NAME.TXT
file is used to communicate to the programmer. The contents of this file are shown after post processing in PartMaker is completed. The first line of this file must be the wordFILES
followed by the names of the output files created that you want the user to view/edit when they press the Edit Program button in PartMaker. Any additional text in the file is for information only, and will be displayed on the screen when post processing is completed.Note: Information written to the OUT_NAME.TXT file is used to communicate to the programmer. The contents of this file are shown after post processing in PartMaker is completed. The first line of this file must be the word FILES followed by the names of the output files created that you want the user to view/edit when they press the Edit Program button in PartMaker. Any additional text in the file is for information only, and will be displayed on the screen when post processing is completed.
#merge MERGEFILE.EXT FILE1.EXT FILE2.EXT FILE3.EXT<eob>
Merge is used to paste files back together in a specific order.
MERGEFILE.EXT
may be any valid file name of the user's choice.
FILE1.EXT
is the first file to be pasted in; FILE2.EXT
, FILE3.EXT
, etc. are any successive files you want to paste into MERGEFILE.EXT
.
#remove FILE1.EXT<eob>
: Any files following #remove
will be deleted at the end of post processing.