V22LatheInstalling-Editing Post Processors
V22LatheInstalling-Editing Post Processors
V22LatheInstalling-Editing Post Processors
1
Installing a Post Processor
Step 3 Under Customer Resources, click on Post Processors (V22 MILL ONLY) or Post Processors
(V22 LATHE ONLY) depending on desired post.
Step 4 Navigate to the desired Post Processor by clicking on the corresponding controller name.
Step 5 Click on the desired Post Processor .exe file, and Save the file to your computer. Note that prior to
the file extension is a date code to verify revision dates. Example: the Haas VF (v22 011408).exe
was last modified on January 14 ,2008.
Step 6 Once Saved to your computer, and with the BobCAD-CAM software closed; double-click on the file
icon and Run, this will automatically launch the installation wizard. Click Next, Install and Finish.
Your Post Processor is now installed into the BobCAD-CAM Version 22 software.
2
Editing a Post Processor
NOTE: Included with your BobCAD-CAM software is free post processor modifications and creation.
Please contact Technical Support at (727) 489-0003 for information regarding a post processor for
your machine controller. This section is intended for those who wish to modify or create a post
processors. This section assumes that the end-user is already familiar with Windows operating
system software.
IMPORTANT:
Be certain to create a copy of your post processor and rename the file, to avoid
overwriting, as saved changes cannot be easily undone.
Create a copy of the post you desire to edit, and rename before editing.
Step 2 To edit the post processor you will first need to open the Lathe Post Editor (or Mill Post Editor)
this is an executable file located in the BobCAD-CAM V22 directory:
3
Step 3 Double-click on the short-cut icon to launch the application:
Note: Most post editing is only slight; requiring only relocating existing variables, changing and or adding
hard output text. All mill and lathe Variables and Commands, with a brief description, are listed in
the end of this document.
The following information is true for both post editors. On the Post tab, you may select the desired
post to be modified. Selection is determined from the pull down menu. You will note in the lower left
hand corner of the window is the Output debug comments check box. This is a handy feature
for determining from which code block the resultant NC code is generated. It will be discussed in
detail, further in this document. The following examples will be based upon the Fanuc 0T.MillPst
post processor, it has been selected for their complete use of standardized G and M codes. Post
can vary considerably, as such, the following examples are purely to be used as a guide. They are
not intend to, nor do they match all machine tool controllers.
4
Lathe - Edit code blocks tab – Starting blocks folder - Program header
After selecting the desired post to be modified, click on the Edit code blocks tab. In these fields is
where you may edit the various information to generate the desired machine tool NC output as
generated by the BobCAD-CAM V22 software. The blocks are programmed using Variables and
Commands, displayed in BLUE. Characters in quotes will be hard-coded, and displayed in RED.
You may encounter a variable in BLACK; this mean that the variable name is misspelled or the
variable is not defined in the PostingVariables.txt file. Even if a Variable or Command is
displayed in BLACK and not defined in the PostingVariables.txt, it still may function.
5
The above example is information contained in the Program header under Starting blocks. In a
future Build it will define the basic stock geometry and tool definitions for the Backplot feature
within the Predator CNC Editor – Level2 software. This information will be located prior to the
hard-coded “%”, indicating the beginning of the NC program file, it will be disregarded by the
controller. The current code blocks are written as follows:
"%"
"O",prog_n,"( PROGRAM NUMBER )"
default_add_spaces This command outputs nothing, only adds spaces to the program
() NC file start
% Percent sign indicating start of NC file
O00001 ( PROGRAM NUMBER ) Program number as defined in the BobCAD software, no line number
Lathe - Edit code blocks tab – Starting blocks folder – Program start turning
The above example is information contained in the Program start turning. It is used to output
information regarding the program creation, any user comments, initial safety line, first tool change
and location of first machining operation. The code blocks are written as follows:
6
"( TIME: ",output_time," )"
user_comment_1
user_comment_2
user_comment_3
user_comment_4
user_comment_5
user_comment_6
user_comment_7
user_comment_8 The user comment will only display is selected to output and the field contains text
user_comment_9
user_comment_10
user_comment_11
user_comment_12
user_comment_13
user_comment_14
user_comment_15
output_tool_list
start_comment," ",end_comment
n,"G18",inch_mode,cancel_offset,"G80",absolute_coord,"G98"
start_comment,end_comment
n,rapid_move,"G28","U0.","W0."
start_comment,comment1,end_comment
start_comment,comment2,end_comment
n_forced,t
n,optional_stop
start_comment," ",end_comment
n,"G50",smax
n,"G97",out_css_rpm,spindle_on
n,rapid_move,"G54",force_x,xr,force_z,zr,coolant_on
n,spsp_code,s
Lathe - Edit code blocks tab – Ending blocks folder – End of program turning
The End of program turning under Ending blocks, should contain information for turning off
operations and returning to a home or safe position.
7
The above example is information contained in the End of program turning. It is used to output
variables regarding the program end of file, turning off operations and returning to a safe location.
The code blocks are written as follows:
n,"M09"
n,spindle_off
start_comment," ",end_comment
n,rapid_move,"G28","U0.","W0."
n,"M30"
"%"
The Misc. folder contains the following fields for various code block definition, for calling within the
post in other fields:
Cutter comp. left "G41"
Cutter comp. right "G42"
Cutter comp. off "G40"
Tool length comp. "G43"
8
Lathe - Edit code blocks tab – Tool Change folder – Tool change turning
The Tool Change folder contains the Tool change turning, the Same tool turning and the Same
tool facing fields. These define how a tool change is to be executed in the NC file.
The above example is a code block definition contained in the Tool change turning field. It is used
to output variables regarding turning off operation, moving to the tool change position, executing the
change and moving to the next machining operation. You will note that the code blocks are similar,
if not the same as, the first tool change defined in the Program start turning. The code blocks are
written as follows:
n,"M09"
n,spindle_off
start_comment," ",end_comment
n,rapid_move,"G28","U0.","W0."
start_comment,comment1,end_comment
start_comment,comment2,end_comment
n_forced,t
n,optional_stop
start_comment," ",end_comment
n,"G50",smax
n,"G97",out_css_rpm,spindle_on
n,rapid_move,"G54",force_x,xr,force_z,zr,coolant_on
n,spsp_code,s
9
( ) Start of speeds and move to machining location
N214 G50 S3000 Set maximum spindle speed
N215 G97 S2750 M03 RPM mode, speed and spindle on
N216 G54 X.3125 Z0. M08 Work coordinate, move to location and coolant on
N217 G96 S450 Change to CSS mode and speed
Lathe - Edit code blocks tab – Tool Change folder – Same tool turning / grooving
Since the lathe philosophy and theory are different then mill, as far as the NC program layout, each
cut is treated much like a program unto itself. As such,the Same tool turning and the Same tool
facing fields are the same as the Tool change turning. This may NOT be the case for all machine
tool controllers (post processors), but this applies to the current example. No fields are shown.
Lathe - Edit code blocks tab – Rapid moves folder
The Rapid moves folder contains all code block definitions for rapid moves within the NC file. It
contains the following fields:
10
The Turning/Facing Operations folder contains all the fields for defining the code blocks for each
canned cycle start and the independent termination of each cycle. It contains the following fields:
Turning/Facing Operations - Auto finish canned cycles (G70)
n,"M09"
n,spindle_off
start_comment," ",end_comment
n,rapid_move,"G28","U0.","W0."
start_comment,comment1,end_comment
start_comment,comment3,end_comment
n_forced,f_tool
n,optional_stop
start_comment," ",end_comment
n,"G50",smax
n,"G97",out_finish_css_rpm,spindle_on
n,rapid_move,"G54",force_x,xr,force_z,zr,coolant_on
n,spsp_code,finish_s
n,"G70",n_first_finish,n_last_finish,finish_feed
n,cancel_offset
n,"G97"
n_forced,f_special
newvars
The corresponding output will be posted as follows (when selected in the Feature):
n,"G71",roughing_depth_of_cut_x,rough_retract_amount
n,"G71",n_first_rough,n_last_rough,rough_x_allowance,rough_z_allowance,rough_feed
The corresponding output will be posted as follows (when selected in the Feature):
N09 G71 U.1 R.1 G71 Rough turning cycle – Two line format
N10 G71 P11 Q20 U.05 W.05 F15. Executes G71 Rough turning cycle for
N11 G00 X-.0156 line 11 through 20 with established parameters
N12 G42 G01 X.7834
N13 G03 X.9153 Z-.0919 I-.1406 K0.
N14 G01 X1. Z-.3209
N15 Z-.7656
N16 G02 X1.1977 Z-.9971 I0. K.2344
N17 G01 X1.256 Z-1.0063
N18 G03 X1.6365 Z-1.285 I-.5093 K-.0806
N19 G01 X2. Z-2.0119
N20 Z-2.7656
11
Turning/Facing Operations - Rough turning end
n,cancel_offset
n,"G97"
n_forced,special
n,"G72",roughing_depth_of_cut_z,rough_retract_amount
n,"G72",n_first_rough,n_last_rough,rough_x_allowance,rough_z_allowance,rough_feed
The corresponding output will be posted as follows (when selected in the Feature):
N09 G72 W.1 R.1 G72 Rough facing cycle – Two line format
N10 G72 P11 Q20 U.05 W.05 F15. Executes G72 Rough facing cycle for
N11 G00 X-.0156 line 11 through 20 with established parameters
N12 G42 G01 X.7834
N13 G03 X.9153 Z-.0919 I-.1406 K0.
N14 G01 X1. Z-.3209
N15 Z-.7656
N16 G02 X1.1977 Z-.9971 I0. K.2344
N17 G01 X1.256 Z-1.0063
N18 G03 X1.6365 Z-1.285 I-.5093 K-.0806
N19 G01 X2. Z-2.0119
N20 Z-2.7656
n,cancel_offset
n,"G97"
n_forced,special
n,"G73",finish_x_spring_pass_stock_radius,finish_z_spring_pass_stock_radius
,finish_number_of_cuts_two_line
n,"G73",n_first_rough,n_last_rough,finish_x_allowance,finish_z_allowance
,rough_feed
The corresponding output will be posted as follows (when selected in the Feature):
N33 G73 U.04 W.04 R5 G73 Finish turning cycle – Two line format
N34 G73 P35 Q45 U0. W0. F5. Executes G73 Rough turning cycle for
N35 G00 X-.0156 line 35 through 45 with established parameters
N36 G42 G01 X.7834
N37 G03 X.9153 Z-.0919 I-.1406 K0.
N38 G01 X1. Z-.3209
N39 Z-.7656
N40 G02 X1.1977 Z-.9971 I0. K.2344
N41 G01 X1.256 Z-1.0063
N42 G03 X1.6365 Z-1.285 I-.5093 K-.0806
N43 G01 X2. Z-2.0119
N44 Z-2.7656
N45 G00 Z0.
12
Turning/Facing Operations - Finish turning end
n,cancel_offset
n,"G97"
n_forced,special
n,"G75",groove_retract_amount
n,"G75",groove_x_bottom,groove_z_bottom,groove_peck_increment,groove_depth_of_cut
,groove_rvalue,rough_feed
The corresponding output will be posted as follows (when selected in the Feature):
N72 G75 R.1 G75 Groove turning cycle – Two line format
N73 G75 X5. Z-2.5838 I0. K.05 R0. F12. Executes G75 Groove turning cycle
n,cancel_offset
n,"G97"
n_forced,special
n,"G74",groove_retract_amount
n,"G74",groove_x_bottom,groove_z_bottom,groove_peck_increment,groove_depth_of_cut
,groove_rvalue,rough_feed
The corresponding output will be posted as follows (when selected in the Feature):
N58 G74 R.1 G74 Groove facing cycle – Two line format
N59 G74 X.5625 Z5. I.025 K.025 R0. F10. Executes G74 Groove facing cycle
n,cancel_offset
n,"G97"
n_forced,special
13
Turning/Facing Operations - Drill facing start (G74)
n,"G74",groove_retract_amount
n,"G74",groove_x_bottom,groove_z_bottom,groove_peck_increment,groove_depth_of_cut
,groove_rvalue,rough_feed
The corresponding output will be posted as follows (when selected in the Feature):
N103 G74 R.1 G74 Drill facing cycle – Two line format
N104 G74 X0. Z-1. I0. K.25 R0. F12. Executes G74 Drill facing cycle
n,thread_angle_out_start
n,"G76",thread_angle_in,thread_last_cut,thread_machine_allowance
n,"G76",thread_x2,thread_z2,thread_height,thread_first_cut,thread_lead
n,thread_angle_out_end
The corresponding output will be posted as follows (when selected in the Feature):
14
Turning/Facing Operations - Threading end
n,cancel_offset
n,"G97"
n_forced,special
n,thread_g33_gcode,thread_g33_xmove,thread_g33_zmove,thread_g33_feedrate
The corresponding output will be posted as follows (when selected in the Feature):
N88G33 X1.9579 Z-2. F.0714 Start of G33 Simple thread cut move
N89 X2.0619
N90 X1.6522 Z-1.1807
N91 X1.5285
n,thread_g33_gcode,thread_g33_xmove,thread_g33_zmove,thread_g33_feedrate
The corresponding output will be posted as follows (when selected in the Feature):
N92G33 X1.9381 Z-2. F.0714 Start of G33 Simple thread line move
N93 X2.0619
N94 G00 X5.
N95 Z5.
In this post processor case the field is blank. The corresponding output will be posted as follows (for
all, depending on Feature parameters selection):
n,cancel_offset
n,"G97"
n_forced,special
n,"M09"
n,spindle_off
15
The corresponding output will be posted as follows (for all):
n,cancel_offset
n,"G97"
n,special
start_comment," ",end_comment
"( STOCK FEED )"
start_comment," ",end_comment
rapid_to_pickup_z
rapid_to_position_x
n,"M11"
n,"G04","X.5"
rapid_to_stock_feed_z
n,"G04","X.5"
n,"M10"
n,"G04","X.5"
rapid_to_position_z
( )
( STOCK FEED ) Stock feed start
( )
N149 Z0. Rapid to Z pick up
N150 X2. Rapid to X position
N151 M11 Clamp off
N152 G04 X.5 Dwell for 0.5 seconds
N153 Z-3.25 Rapid to stock feed Z location
N154 G04 X.5 Dwell for 0.5 seconds
N155 M10 Clamp on
N156 G04 X.5 Dwell for 0.5 seconds
N157 Z3. Rapid to Z position
16
The following tabs in the Lathe Post Editor contain small fields and check boxes for editing
and tuning the NC program file to the required output. They are self explanatory, as such, we will
not show an output for each field change. The best method for understanding the functionality is;
edit a single field, save the post file and re-post NC code to view results.
The Format tab contains fields to define or select which code is Modal output (or not), how
Sequence numbers output, leading and trailing output for Real numbers, Drilling canned cycles
for controller (blank), amount of Arc sweep type, Arc center type, # of digits for Program
Numbers, Add spaces to NC file, # of digits for G code, Output for reversing signs, X Output for
Radius or Diameter mode, Coordinates sign, Depth format, Canned cycles type and Tool
numbering and offset definitions.
17
Lathe – Misc. parameters tab
The Misc. parameters tab contains fields to define or select the Misc strings for comments and
block deletes, Cutting conditions to set maximum spindle speeds and gear ranges, Tools for
defining tool number and offset output and Two line canned cycles retract and allowances.
18
Lathe – G Codes tab
The G Codes tab contains fields to enter the format of the Defined variables to be output in the NC
file and the Work Offsets number, g code definition and number of offsets.
19
Lathe – M Codes tab
The M Codes tab contains fields to enter the format of the Defined variables to be output in the NC
file.
20
Lathe – Prefixes tab
The Prefixes tab contains fields to enter the format of the Defined variables to be output in the NC
file.
21
Lathe – Notes on Editing the Code blocks field – Getting Variables/Commands
All Commands and Variables can be pulled-up (displayed) and selected when editing a field in the
Edit code blocks tab. Simply place your cursor at the location to enter the desired variables and or
commands. Right-click, and select the desired folder, Get Variable or Get Command.
22
A new window called, Commands – Variables will display. You may change selections by
clicking on the corresponding Post Commands or Post Variables tab. Select the desired folder,
by click on the on the pull-down menu and then double-clicking on the variable name. You may also
high-light the variable name and click OK.
With either method the high-lighted variable will be placed in the location we determine in the Edit
code blocks field. As you will see, it is quite easy to build the Edit code blocks fields to generate
the NC file for your machine tool with your edited post processor.
23
Lathe – Notes on Editing the Code blocks field – Outputting debug comments
On the Post tab in the lower left-hand corner is the Output debug comments check box. If you
check the box, and click Save, the code will post with comments. These comments will indicate
where the Edit code block field and the resultant output was derived.
24
The example below this a program using Output debug comments (high-lighted in yellow).
25
N33 G70 P11 Q20 F.015
N34 G40
N35 G97
N36 T0200
**********5 - Ending blocks//End of program turning **********
N37 M09
N38 M05
( )
N39 G00 G28 U0. W0.
N40 M30
%
You will note that each debug comment has a number prefix, this corresponds to the function
number in the .MillPst file. Remember to turn off Output debug comments, Save the changes and
re-post code; prior to saving or sending the NC file to your machine tool.
The example below this the same program with Output debug comments turned off and the
corresponding code blocks listed to the right of each line.
% "%"
O00001 ( PROGRAM NUMBER ) "O",prog_n,"( PROGRAM NUMBER )"
( PROGRAM START - TURNING CYCLES ) "( PROGRAM START - TURNING CYCLES )"
( PROGRAM NAME: POST TEST.NC) "( PROGRAM NAME: ",prog_name," )"
( POST: FANUC 0T ) "( POST: FANUC 0T )"
( DATE: MON. 02/04/2008) "( DATE: ",output_date," )"
( TIME: 03:49PM) "( TIME: ",output_time," )"
( ) start_comment," ",end_comment
N01 G18 G20 G40 G80 G90 G98 n,"G18",inch_mode,cancel_offset,"G80",absolute_coord
,"G98"
() start_comment," ",end_comment
N02 G00 G28 U0. W0. n,rapid_move,"G28","U0.","W0."
(JOB 0 ROUGH CYCLE ) start_comment,comment1,end_comment
(TOOL #1 80 DEG. 1/64 ROUGH TURNING ) start_comment,comment2,end_comment
N03 T0101 n_forced,t
N04 M01 n,optional_stop
( ) start_comment," ",end_comment
N05 G50 S3000 n,"G50",smax
N06 G97 S477 M03 n,"G97",out_css_rpm,spindle_on
N07 G54 X2. Z0. M08 n,rapid_move,"G54",force_x,xr,force_z,zr,coolant_on
N08 G96 S500 n,spsp_code,s
N09 G71 U.1 R.1 n,"G71",roughing_depth_of_cut_x,rough_retract_amount
N10 G71 P11 Q20 U.05 W.05 F15. n,"G71",n_first_rough,n_last_rough,rough_x_allowance
,rough_z_allowance,rough_feed
N11 G00 X-.0156 n,rapid_move,xr,zr
N12 G42 G01 X.7834 n,cc,feed_move,x_f,z_f,f
N13 G03 X.9153 Z-.0919 I-.1406 K0. n,g_arc_move,x_f,z_f,arc_center,f
N14 G01 X1. Z-.3209 n,cc,feed_move,x_f,z_f,f
N15 Z-.7656 n,cc,feed_move,x_f,z_f,f
N16 G02 X1.1977 Z-.9971 I0. K.2344 n,g_arc_move,x_f,z_f,arc_center,f
N17 G01 X1.256 Z-1.0063 n,cc,feed_move,x_f,z_f,f
N18 G03 X1.6365 Z-1.285 I-.5093 K-.0806 n,g_arc_move,x_f,z_f,arc_center,f
N19 G01 X2. Z-2.0119 n,cc,feed_move,x_f,z_f,f
N20 Z-2.7656 n,cc,feed_move,x_f,z_f,f
N21 G40 n,cancel_offset
N22 G97 n,"G97"
N23 T0100 n_forced,special
N24 M09 n,"M09"
N25 M05 n,spindle_off
( ) start_comment," ",end_comment
N26 G00 G28 U0. W0. n,rapid_move,"G28","U0.","W0."
(JOB 0 ROUGH CYCLE ) start_comment,comment1,end_comment
(TOOL #2 80 DEG. 1/64 FINISH TURNING ) start_comment,comment3,end_comment
N27 T0201 n_forced,f_tool
N28 M01 n,optional_stop
( ) start_comment," ",end_comment
26
N29 G50 S3000 n,"G50",smax
N30 G97 S429 M03 n,"G97",out_finish_css_rpm,spindle_on
N31 G54 X-.0156 Z0. M08 n,rapid_move,"G54",force_x,xr,force_z,zr,coolant_on
N32 G96 S450 n,spsp_code,finish_s
N33 G70 P11 Q20 F.015 n,"G70",n_first_finish,n_last_finish,finish_feed
N34 G40 n,cancel_offset
N35 G97 n,"G97"
N36 T0200 n_forced,f_special
N37 M09 n,"M09"
N38 M05 n,spindle_off
( ) start_comment," ",end_comment
N39 G00 G28 U0. W0. n,rapid_move,"G28","U0.","W0."
N40 M30 n,"M30"
% "%"
Lathe – Notes on Editing the Code blocks field – Post text file
The .LathePst are actually ASCII text files, as such they may be opened with a text editor.
NotePad, NotePad++ or the Predator CNC Editor may be used to manually edit the post
processor file without going through the Lathe Post Editor application.
IMPORTANT:
Extreme care should be taken when editing with a text editor application, since you cannot verify
the variable spelling or post format and the text color will not be indicated.
The file below is the Fanuc 0T.LathePst file, opened in the Predator CNC Editor.
0. File Header.
"%"
"O",prog_n,"( PROGRAM NUMBER )"
default_add_spaces
27
n,absolute_coord,"G80",cancel_offset,inch_mode
n_forced,rapid_move,"G28","U0.","W0."
start_comment,comment1,end_comment
start_comment,comment2,end_comment
n,"M45"
n,"G28","H0"
n,rapid_move,"G54","G97","S100",t,live_spindle_on
8. Set debug.
debug_off
28
13. Tool length compensation.
"G43"
29
n,cancel_offset
n,"G97"
n_forced,special
220. Is X modal? y
222. Is Z modal? y
223. Are the g codes modal? y
30
224. Are the xy (or yz or xz) coordinates modal in arc milling? y
225. Are the g codes (G02 and G03) modal in arc milling? y
228. Output sequence numbers? y
230. Delete the decimal point? n
231. Delete leading zeros? y
232. Delete trailing zeros? y
234. Places before decimal point for reals? 1
235. Number of places for G and M codes? 1
236. Places after decimal for feedrate ? 4
237. Scale factor for feedrate ? 1
239. Add spaces to the program? y
241. Break arcs into quadrants? n
242. Arc center a=absolute, b=incremental, d=unsigned inc., e=radius? b
243. Break arcs into two pieces if greater than 180 degrees? n
247. Sign of X Spindle 1 (p = pos, n = neg, e = either, r = reverse)? e
248. Sign of X Spindle 2 (p = pos, n = neg, e = either, r = reverse)? e
249. Output X as a diameter or radius (d/r)? r
250. Use canned cycle for drilling? n
251. Use canned cycle for peck drilling? n
252. Use canned cycle for chip break? n
253. Use canned cycle for tap? n
254. Use canned cycle for bore #1? n
255. Use canned cycle for bore #2? n
258. Use two line canned cycle format? y
259. Depth format (d = default, t = trailing)? d
260. Amount to add to t to obtain t1? 0
261. Amount to add to t to obtain t2? 0
262. Value of t1 at t = 0? 0
263. Value of t2 at t = 0? 0
265. Places before decimal point for angles? 1
300. Number of places for sequence numbers? 2
302. Number of places for program number? 5
411. R value (Retract amount) for first line of 2 line rough cycle? 0.1
412. R value (Retract amount) for first line of 2 line groove cycle? 0.1
413. R value (Thread machine allowance) 2 line G76 cycle? 0.001
31
773. Coolant on String ? "M08"
774. Coolant off String ? "M09"
780. Symbol for Spindle Speed ? "S"
781. Symbol for Tool Number Prefix ? "T"
782. Spindle forward String ? "M03"
783. Spindle reverse String ? "M04"
784. Spindle off String ? "M05"
785. Symbol for CSS spindle speed? "G96"
786. Symbol for RPM spindle speed? "G97"
787. Code for low spindle gear? "M40"
788. Code for medium spindle gear? "M41"
789. Code for high spindle gear? "M42"
790. Prefix for canned cycle start line Number? "P"
791. Prefix for canned cycle end line Number? "Q"
792. Prefix for thread G76 first cut amount? "D"
793. Prefix for thread height? "K"
794. Prefix for thread angle in? "P"
795. Prefix for thread last cut amount? "Q"
796. Prefix for thread machine allowance? "R"
797. GCode for Rapid Move? "G00"
798. GCode for Feed Move? "G01"
799. GCode for Arc CW? "G02"
800. GCode for Arc CCW? "G03"
801. Prefix for X Move? "X"
802. Prefix for Y Move? "Y"
803. Prefix for Z Move? "Z"
804. Prefix for Rough Cycle depth of cut? "D"
805. Prefix for Rough Cycle stock allowance X? "U"
806. Prefix for Rough Cycle stock allowance Z? "W"
807. Prefix for Rough Cycle retract amount? "R"
808. Prefix for Finish Cycle stock allowance X? "U"
809. Prefix for Finish Cycle stock allowance Z? "W"
810. Prefix for Finish Cycle X stock amount for spring passes? "U"
811. Prefix for Finish Cycle Z stock amount for spring passes? "W"
812. Prefix for Groove Cycle retract amount? "R"
813. Prefix for Groove Cycle X bottom? "X"
814. Prefix for Groove Cycle Z bottom? "Z"
815. Prefix for Groove Cycle depth of cut? "K"
816. Prefix for Groove Cycle peck increment? "I"
822. GCode for simple threading cycle? "G33"
823. Prefix for X depth for roughing cycle? "U."
824. Prefix for Z depth for roughing cycle? "W."
825. Prefix for groove dwell? "D"
826. Prefix for groove peck clearance? "R"
827. Prefix for groove peck retract? "R"
32
Customization Variables and Commands for Lathe Post Processing
Commands
oldvars = use old position variables and misc. variables.
newvars = use new position position and misc. variables.
force_x = force the x value to be output next time even if modal.
force_y = force the y value to be output next time even if modal.
force_z = force the z value to be output next time even if modal.
force_drill_z = force the z value for drilling to be output next time even if modal.
memo_xmove = Memorize the current x movement for use later.
memo_ymove = Memorize the current y movement for use later.
memorize_line_number = Memorize sequence number for use later.
memorized_line_number = Use memorize sequence number.
debug_on = Turns on automatic debug comments in post output.
debug_off = Turns off automatic debug comments in post output.
outputxmemo = Output X value from memo_xmove
outputymemo = Output Y value from memo_ymove
start_add_block_delete = Add block delete to all lines until stop_add_block_delete is used
stop_add_block_delete = Stop adding block delete that started from using start_add_block_delete
force_no_add_spaces = Force no spaces even when default is set to add spaces.
default_add_spaces = Set add spaces back to condition before force_no_add_spaces was called.
output_tool_list = Output tool list.
Variables – Positioning
rapid_move = Output rapid move (G00).
feed_move = Output feed move (G01).
arc_move = Output arc feed move (G02,G03).
cr = C rapid with live tool, diameter and face machining.
xr = X rapid with live tool, diameter and face machining.
zr = Z rapid with live tool, diameter and face machining.
crl = C rapid with live tool, diameter and face machining.
xrl = X rapid with live tool, diameter and face machining.
zrl = Z rapid with live tool, diameter and face machining.
xh = X home position.
zh = Z home position.
xhl = X home position with live tooling.
zhl = Z home position with live tooling.
home = X, Z tool home position.
prev_x = Previous X position.
prev_z = Previous X position.
rapid_to_pickup_z =
rapid_to_position_x =
rapid_to_position_z =
rapid_to_stock_feed_z =
rapid_iplane_face = Rapid to iplane in face live tool (G0 Z.1)
rapid_rplane_face = Rapid to rplane in face live tool (G0 Z.1)
rapid_iplane_diam =
rapid_rplane_diam =
pos_rpm = Position move in RPM mode.
pos_rpm_prev = Position move with previous RPM.
33
Variables – Comments
prog_n = Program number.
prog_name = Program name.
output_date = Output current date.
comment1 = Job comment.
comment2 = Tool comment.
comment3 = Finish tool comment.
start_comment = Output start of comment string.
end_comment = Output end of comment string.
user_comment_1 = Output user comment 1 in Turning tools, Current settings, Posting
user_comment_2 = Output user comment 2 in Turning tools, Current settings, Posting
user_comment_3 = Output user comment 3 in Turning tools, Current settings, Posting
user_comment_4 = Output user comment 4 in Turning tools, Current settings, Posting
user_comment_5 = Output user comment 5 in Turning tools, Current settings, Posting
user_comment_6 = Output user comment 6 in Turning tools, Current settings, Posting
user_comment_7 = Output user comment 7 in Turning tools, Current settings, Posting
user_comment_8 = Output user comment 8 in Turning tools, Current settings, Posting
user_comment_9 = Output user comment 9 in Turning tools, Current settings, Posting
user_comment_10 = Output user comment 10 in Turning tools, Current settings, Posting
user_comment_11 = Output user comment 11 in Turning tools, Current settings, Posting
user_comment_12 = Output user comment 12 in Turning tools, Current settings, Posting
user_comment_13 = Output user comment 13 in Turning tools, Current settings, Posting
user_comment_14 = Output user comment 14 in Turning tools, Current settings, Posting
user_comment_15 = Output user comment 15 in Turning tools, Current settings, Posting
Variables – Tools
t = Output first tool number without prefix.
f_tool = Canned cycle auto finish tool number.
t1 = Tool number + #260 (without "T" prefix)
t2 = Tool number + #261 (without "T" prefix)
special = Tool number with offset canceled (ex. T0100)
f_special = Finish tool number with offset canceled (ex. T0100)
n_tool = N word with tool number.
n_ftool = N word with finish tool number.
first_tool = First tool number without 'T' code.
next_tool = Next tool number without 'T' code.
p_tool_num = P word with tool number for G10 line.
p_ftool_num = P word with finish tool for G10 line.
p_special = P word G10 line tool number with offset canceled.
Variables – M Codes
coolant_on = M08 if coolant used, null if coolant not used.
coolant_off = M09 if coolant used, null if coolant not used.
live_spindle_on = M code for live tool on.
spindle_on = M03,M04 code for spindle on.
spindle_off = M05 code for spindle off
stop = M00 for program stop
optional_stop = M01 for program optional stop
Variables – Offset
cc = Cutter compensation code (G41,G42).
h = Output length offset register with prefix.
34
Variables – Misc. Codes
s = Output spindle speed with prefix "S1000".
finish_s = Output finish spindle speed with prefix "S1000".
smax = Maximum spindle speed.
sp_on_css = Spindle on using constant surface speed.
sp_on_rpm = Spindle on using RPM.
spsp_code = Rough spindle speed code (G96, G97).
spindle_gear = Output spindle gear.
g112 = Activate G112 live tooling mode.
g113 = Cancel G112 live tooling mode.
mill_radius_string = R word with live tool radius.
out_css_rpm = Output rough spindle speed in CSS/RPM mode
out_finish_css_rpm = Output finish spindle speed in CSS/RPM mode
finish_spsp_code = Finish spindle speed code (G96, G97).
35
Variables – Threading Canned Cycles - Cont'd
36