0% found this document useful (0 votes)
197 views81 pages

306 NCI File

This chapter provides detailed descriptions of the codes used in Mastercam's NCI file, which is the intermediate file from which the NC program is produced. The code definitions are presented numerically by NCI Gcode and include the gcode, function, parameters, and possible parameter values. The NCI Gcodes are then summarized by product, including codes for lathe, mill, and router NCI Gcodes.

Uploaded by

Hoang Lam
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
197 views81 pages

306 NCI File

This chapter provides detailed descriptions of the codes used in Mastercam's NCI file, which is the intermediate file from which the NC program is produced. The code definitions are presented numerically by NCI Gcode and include the gcode, function, parameters, and possible parameter values. The NCI Gcodes are then summarized by product, including codes for lathe, mill, and router NCI Gcodes.

Uploaded by

Hoang Lam
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 81

Volume 3 Chapter 6 The NCI File

6 The NCI File

This chapter provides detailed descriptions of the codes used in Mastercam’s NCI file, which is the
intermediate file from which the NC program is produced. For information on the structure and use of
the NCI file, see Volume 1, The NCI File.
The code definitions are presented in numerical order by NCI Gcode, that is, the first line of data in
each pair of NCI lines. The definition format is:
Gcode and function.
M indicates used in Mill only.
L indicates used in Wire only.
M 0 or 1 Linear Move)

Parameters positions.
g Numbers correlate to explanation
1 2 3 4 5 6 in following table.

g 0 Linear move at rapid rate gcode


1 Linear move at feed rate gcode
1 Cutter compensation use cc 0 Cutter compensation modal
40 Cancel cutter compensation in the control
Parameter use. 41 Cutter compensation in the control = left
42 Cutter compensation in the control = right
Predefined variable 140 Cancel cutter compensation last move in the contour
where parameter is
2 X position xnci (x)
stored.
3 Y position ynci (y)
4 Z position znci (z)
5 Feed Rate settings Possible variable
fr Positive Feed Rate
values and -1 Unchanged
interpretation.
-2 Rapid
6 Control flags

In some cases, more than one post variable receives a single NCI parameter. For example, the second
parameter for Gcode 1 lists both the raw NCI variable xnci as well as the calculated variable x. The
calculated variable is always listed second.
Note: It is important to understand that the value, sign, and format of the calculated variable may be
different than that of the corresponding NCI variable and that you would usually use the calculated
variable.
Also note that it is recommended to use the following calculated variables.

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-1


Chapter 6 The NCI File Volume 3

NCI Gcode Summaries


This section contains tables that group NCI Gcodes by product.

L Lathe NCI Gcodes

M Mill NCI Gcodes

R Router NCI Gcodes

W Wire NCI Gcodes

L Lathe NCI Gcodes


Gcode Description
0 Linear move at rapid rate
1 Linear move at feed rate
2 Arc move, clockwise
3 Arc move, counterclockwise
4 Dwell and spindle change
80 Cancel canned cycle
81 Start canned cycle
82 Additional (custom) canned cycle parameters
200 Threading parameters (one)
201 Threading parameters (two)
900 Stock transfer (Lathe Miscelaneous Operations )
901 Stock flip (Lathe Miscelaneous Operations )
902 Stock advance (Lathe Miscelaneous Operations )
903 Chuck (Lathe Miscelaneous Operations )
904 Tail stock (Lathe Miscelaneous Operations )
905 Steady rest (Lathe Misc Ops )
911 Miscellaneous reals (Lathe Miscelaneous Operations )
912 Miscellaneous integers (Lathe Miscelaneous Operations )
1000 Null tool change
1001 Start-of-file tool change
1002 Tool change
1003 End of file
1004 Cancel cutter compensation
1005 Manual entry comment (before current block)
1006 Manual entry comment (after current block)
1007 Manual entry comment (with current block)

6-2 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

Gcode Description
1008 Tool operation comment
1011 Define miscellaneous reals
1012 Define miscellaneous integers
1013 Define miscellaneous parameters
1014 Tool plane view matrix
1016 Additional miscellaneous parameters
1017 Construction plane view matrix
1018 Subprogram start definition
1019 Subprogram end definition
1020 Stock parameters
1025 Canned text
1027 Working Coordinate System parameters
1050 NCI Version header
10000 Toolpath additional parameters
20000 Tool additional parameters

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-3


Chapter 6 The NCI File Volume 3

M Mill NCI Gcodes


Gcode Description

0 Linear move at rapid rate


1 Linear move at feed rate
2 Arc move, clockwise
3 Arc move, counterclockwise
4 Dwell and spindle change
11 5-axis move
80 Cancel drill cycle
81 Start drill cycle
82 Additional (custom) drill cycle parameters
100 Canned cycle repeat position
1000 Null tool change
1001 Start of file tool change
1002 Tool change
1003 End of file
1004 Cancel cutter compensation
1005 Manual entry comment (before current block)
1006 Manual entry comment (after current block)
1007 Manual entry comment (with current block)
1008 Tool operation comment
1011 Define miscellaneous reals
1012 Define miscellaneous integers
1013 Define miscellaneous parameters
1014 Tool plane view matrix
1016 Additional miscellaneous parameters
1017 Construction plane view matrix
1018 Subprogram start definition
1019 Subprogram end definition
1020 Stock parameters
1025 Canned text
1027 Working Coordinate System parameters
1028 Right Angle Head parameters
1050 NCI Version header
10000 Toolpath additional parameters
20000 Tool additional parameters

6-4 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

R Router NCI Gcodes


Gcode Description

0 Linear move at rapid rate


1 Linear move at feed rate
2 Arc move, clockwise
3 Arc move, counterclockwise
4 Dwell and spindle change
11 5-axis move
80 Cancel drill cycle
81 Start drill cycle
82 Additional (custom) drill cycle parameters
83 Block Drill (canned cycle parameters)
100 Canned cycle repeat position
1000 Null tool change
1001 Start of file tool change
1002 Tool change
1003 End of file
1004 Cancel cutter compensation
1005 Manual entry comment (before current block)
1006 Manual entry comment (after current block)
1007 Manual entry comment (with current block)
1008 Tool operation comment
1011 Define miscellaneous reals
1012 Define miscellaneous integers
1013 Define miscellaneous parameters
1014 Tool plane view matrix
1016 Additional miscellaneous parameters
1017 Construction plane view matrix
1018 Subprogram start definition
1019 Subprogram end definition
1020 Stock parameters
1025 Canned text
1027 Working Coordinate System parameters
1028 Right Angle Head parameters
1050 NCI Version header
10000 Toolpath additional parameters
20000 Tool additional parameters

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-5


Chapter 6 The NCI File Volume 3

W Wire NCI Gcodes


Gcode Description

0 Linear move at rapid rate


1 Linear move at feed rate
2 Arc move, clockwise
3 Arc move, counterclockwise
4 Dwell
11 4-axis taper move
20 Direct 4-axis linear move at rapid rate - lower guide
21 Direct 4-axis linear move at feed rate - lower guide
22 Direct 4-axis arc move, clockwise - lower guide
23 Direct 4-axis arc move, counterclockwise - lower guide
30 Direct 4-axis linear move at rapid rate - upper guide
31 Direct 4-axis linear move at feed rate - upper guide
32 Direct 4-axis arc move, clockwise - upper guide
33 Direct 4-axis arc move, counterclockwise - upper guide
80 Cancel canned (drill) cycle
81 Start canned (drill) cycle
82 Additional (custom) canned cycle parameters
100 Reposition point with current Canned cycle
1000 Null tool change
1001 Start-of-file tool change
1002 Tool change
1003 End of file
1004 Cancel cutter compensation
1005 Manual entry comment (before current block)
1006 Manual entry comment (after current block)
1007 Manual entry comment (with current block)
1008 Tool operation comment
1009 Wire cut length
1010 Wire condition change
1011 Define miscellaneous reals
1012 Define miscellaneous integers
1013 Define miscellaneous parameters
1014 Tool plane view matrix
1015 Subprogram definition
1016 Additional miscellaneous parameters
1020 Stock parameters
1025 Canned text

6-6 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

Gcode Description

1027 Working Coordinate System parameters


1050 NCI Version header
10000 Toolpath additional parameters
20000 Tool additional parameters

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-7


Chapter 6 The NCI File Volume 3

NCI Codes and Definitions


This section describes the Gcodes produced by the Mastercam Mill, Lathe, Router and Wire products.
Some NCI Gcodes are common between these products, while others apply only to a specific product.
Look for these symbols to determine which product(s) the NCI Gcode applies to:

L Lathe

M Mill

R Router

W Wire

Control Flags Parameter: Lathe , Mill, Router, Wire


The control flags (also called “contour flags”) parameter is a single parameter passed from the NCI that
carries several pieces of information in a single numeric value. The control flags parameter appears in
every motion NCI Gcode (Gcodes 0, 1, 2, 11, 81) to control such values as contour start, stop, and end,
coolant, and 5-axis angles (for Mill) or rapid behavior (for Lathe).
Each decimal position in the control flags parameter value represents an individual flag. For example, 1
(first decimal place) is the contour stop flag, 10 (second decimal place) is the contour optional stop flag,
100 (third decimal place) is the contour end flag, and so forth. When added together, the result is a
single number that represents multiple flags. For example, 111 represents the above three flags in their
“on” state. Zero is implied when the place fields are empty, but only leading zeros may be omitted.
Note: The flag as read from the NCI is available as the variable cur_cflg.
You sould rarely need to use the cur_cflg variable directly because the post executable sets separate
variables for each flag.
The Mill control flags parameter carries different flags from the Lathe and Wire control flags. The
following tables describe the settings for each.

6-8 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

M R Mill / Router Control Flags Parameters

Control flags = cur_cflg


cstop
+ cgstop
+ cend
+ cstart
+ coolant
+ rev5
cstop 0 Contour stop off
1 Contour stop on
cgstop 00 Contour optional stop off
10 Contour optional stop on
cend 000 Contour end off
100 Contour end on
cstart 0000 Contour start off
1000 Contour start on
coolant 100000 Coolant off
200000 Coolant flood
300000 Coolant mist
400000 Coolant tool
rev5 1000000 Five axis, non-vertical tool: flipped
Vertical tool: same as previous
angle
2000000 Five axis: same as next angle
3000000 Five axis: 180 degree angle
4000000 Five axis: previous + 180 degrees
5000000 Five axis: next + 180 degrees

For example (in Mill), if:


cur_cflg = 3201001

The control flags (reading left to right) set the following:


5-axis: 180-degree angle
Coolant flood
Contour start on
Contour optional stop off
Contour stop on

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-9


Chapter 6 The NCI File Volume 3

L Lathe Control Flags Parameters

Control flags = cur_cflg


cstop
+ cgstop
+ cend
+ cstart
+ rpd_typ
+ coolant
cstop 0 Contour stop off
1 Contour stop on
cgstop 00 Contour optional stop off
10 Contour optional stop on
cend 000 Contour end off
100 Contour end on
cstart 0000 Contour start off
1000 Contour start on
rpd_typ 10000 Clear to home
20000 Rapid to start
30000 Rapid around obstruction
40000 Rapid between points
50000 Entry / Exit
60000 Start / End rough turning cycles
coolant 100000 Coolant off
200000 Coolant flood
300000 Coolant mist
400000 Coolant tool

6-10 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

W Wire Control Flags Parameters

Control flags = cur_cflg


cstop
+ cgstop
+ cend
+ cstart
+ thrd_cut
+ water
+ power
+ tank
cstop 0 Contour stop off
1 Contour stop on
cgstop 00 Contour optional stop off
10 Contour optional stop on
cend 000 Contour end off
100 Contour end on
200 Wire compensation ON position
cstart 0000 Contour start off
1000 Contour start on
2000 Wire compensation OFF position
thrd_cut 10000 Thread the wire
20000 Cut the wire
water 100000 Water off
200000 Water on
300000 Water option 1
power 1000000 Power off
2000000 Power on
tank 10000000 Tank empty
20000000 Tank fill

Note: Unlike the other contour flags, the Wire Compensation ON/OFF position flag values are added
to cend and cstart flag, if they exist at the same location in the NCI file.
Important note: The wire compensation flags (200 and 2000) are independent of the wire
compensation actually being programming in the wirepath program! They mark where wire
compensation would normally be activated and canceled in the wirepath by Mastercam.
Additionally, the variable cutpos2 is calculated internally from the cstart and cend variables. This
variable indicates the current positon on the wirepath. Wirepaths are relative to the location where
cutter compensation is normally turned on and off.

cutpos2 0 Before comp point


1 On normal comp point
2 In wirepath
3 On normal end comp point
4 After end comp point

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-11


Chapter 6 The NCI File Volume 3

L 0 or 1 (Linear Move)
g
1 2 3 4 5 6

g 0 Linear move at gcode


rapid rate
1 Linear move at gcode
feed rate
1 Cutter compensation cc, 0 Cutter compensation modal
ccomp (no change)
40 Cancel cutter compensation in the
control
41 Cutter compensation in the control
= left
42 Cutter compensation in the control
= right
140 Cancel cutter compensation last
move in the contour
2 Z position znci, x
3 X position xnci, x
4 (Not used)
5 Feed rate fr Positive Feed rate in units per minute
Negative Feed rate in units per revolution
6 Control flags cur_cflg See Control Flags Parameter

Also see “Additional calculated variables” in Volume 1, The NCI File.

6-12 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

M R 0 or 1 (Linear Move)
g
1 2 3 4 5 6

g 0 Linear move at gcode


rapid rate
1 Linear move at gcode
feed rate
1 Cutter compensation cc, 0 Cutter compensation modal
ccomp (no change)
40 Cancel cutter compensation in the
control
41 Cutter compensation in the control
= left
42 Cutter compensation in the control
= right
140 Cancel cutter compensation last
move in the contour
2 X position xnci, x
3 Y position ynci, y
4 Z position znci, z
5 Feed rate fr Positive Feed rate in units per minute
-1 Unchanged
-2 Rapid
6 Control flags cur_cflg See Control Flags Parameter

Also see “Additional calculated variables” in Volume 1, The NCI File.

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-13


Chapter 6 The NCI File Volume 3

W 0, 1, 20, or 21 (Linear Move)


g
1 2 3 4 5 6 7 8 9

g 0 Linear move at gcode


rapid rate
1 Linear move at gcode
feed rate
20 Direct 4-axis lower gcode
guide – linear move
at rapid
21 Direct 4-axis lower gcode
guide – linear move
at feed rate
1 Wire compensation cc, 0 Wire compensation modal
ccomp (no change)
40 Cancel wire compensation in the
control
41 Wire compensation in the control
= left
42 Wire compensation in the control
= right
140 Cancel wire compensation last
move in the contour
2 X position xnci, x
3 Y position ynci, y
4 Z position znci, z
5 Feed rate fr Positive Feed rate in units per minute
-1 Unchanged
6 Wire taper wt
7 Corner type wc 0 Conical
1 Sharp
2 Constant
3 Other
4 Fixed
5 Fishtail
8 Control flags cur_cflg See Control Flags Parameter
9 Corner type radius wc_rad

6-14 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L 2 or 3 (Arc Move)
g
1 2 3 4 5 6 7 8 9 10

g 2 Arc move gcode


clockwise
3 Arc move gcode
counterclockwise
1 Plane position plane (Not used)
2 Cutter compensation cc, 0 Cutter compensation modal
ccomp
40 Cancel cutter compensation in the
control
41 Cutter compensation in the control
= left
42 Cutter compensation in the control
= right
140 Cancel cutter compensation last
move in the contour
3 Z position znci, z
4 X position xnci, x
5 Absolute Z axis arc zc (relative to plane)
center
6 Absolute X axis arc xc (relative to plane)
center
7 (Not used)
8 Feed rate fr Positive Feed rate in units per minute
Negative Feed rate in units per revolution
9 Control flags cur_cflg See Control Flags Parameter
10 Full arc flag full_arc_flg 0 NOT a full arc move
1 Full arc move (360-degree sweep)

Also see “Additional calculated variables” in Volume 1, The NCI File.

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-15


Chapter 6 The NCI File Volume 3

M R 2 or 3 (Arc Move)
g
1 2 3 4 5 6 7 8 9 10

g 2 Arc move gcode


clockwise
3 Arc move gcode
counterclockwise
1 Plane position plane 0 XY plane
1 YZ plane
2 XZ plane
2 Cutter compensation cc, 0 Cutter compensation modal
ccomp (no change)
40 Cancel cutter compensation in the
control
41 Cutter compensation in the control
= left
42 Cutter compensation in the control
= right
140 Cancel cutter compensation last
move in the contour
3 X position xnci, x
4 Y position ynci, y
5 Absolute X axis arc xc (relative to plane)
center
6 Absolute Y axis arc yc (relative to plane)
center
7 Z position znci, z
8 Feed rate fr Positive Feed rate per minute
Negative Feed rate per revolution
-1 Unchanged
-2 Rapid
9 Control flags cur_cflg See Control Flags Parameter
10 Full arc flag full_arc_flg 0 NOT a full arc move
1 Full arc move (360-degree sweep)

Also see “Additional calculated variables” in Volume 1, The NCI File.

6-16 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

W 2, 3, 22, or 23 (Arc Move)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15

g 2 Arc move gcode


clockwise
3 Arc move gcode
counterclockwise
22 Direct 4-axis lower gcode
guide – arc move
clockwise
23 Direct 4-axis lower gcode
guide – arc move
counterclockwise
1 (Not used)
2 Wire compensation cc, 0 Wire compensation modal
ccomp (no change)
40 Cancel wire compensation in the
control
41 Wire compensation in the control
= left
42 Wire compensation in the control
= right
140 Cancel wire compensation last
move in the contour
3 X position xnci, x
4 Y position ynci, y
5 Absolute X-axis arc xc (relative to plane)
center
6 Absolute Y-axis arc yc (relative to plane)
center
7 Z position znci, z
8 Feed rate fr Positive Feed rate per minute
-1 Unchanged
9 Wire taper wt
10 Corner type wc 0 Conical
1 Sharp
2 Constant
3 Other
4 Fixed
5 Fishtail
11 Control flags cur_cflg See Control Flags Parameter
12 Corner type radius wc_rad
13 Arc type warc_ctyp 0 Conical
1 Sharp
2 Constant
3 Other
November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-17
Chapter 6 The NCI File Volume 3

4 Fixed
5 Fish Tail
14 Arc type radius wcor_rad
15 Full arc flag full_arc_flg 0 NOT a full arc move
1 Full arc move (360-degree sweep)

Also see “Additional calculated variables” in Volume 1, The NCI File.

6-18 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L 4 (Dwell and Spindle Change)


g
1 2 3

g 4 gcode
1 Dwell dwell Dwell time
2 Spindle speed ss Positive Spindle speed in RPM
0 Spindle stop
Negative Spindle speed in surface units per
minute
3 (Not used)

M R 4 (Dwell and Spindle Change)


g
1 2 3

g 4 gcode
1 Dwell dwell Dwell time
2 Spindle speed ss Positive Spindle forward
0 Spindle stop
Negative Spindle reverse
3 Spindle direction spdir

W 4 (Dwell)
g
1 2 3

g 4 gcode
1 Dwell dwell Dwell time
2 (Not used)
3 (Not used)

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-19


Chapter 6 The NCI File Volume 3

M R 11 (5-Axis Move)
g
1 2 3 4 5 6 7 8 9 10 11 12

g 11 gcode
1 X position xnci, x
2 Y position ynci, y
3 Z position znci, z
4 U position u
5 V position v
6 W position w
7 Feed rate fr Positive Feed rate
-1 Unchanged
-2 Rapid
8 *Tool parameters = ‘nnn’
rev5+cutpos+cuttyp
rev5 000 Zero angle
100 5-axis flip (not vertical), same angle
as previous
200 Same angle as next
300 180-degree angle
400 Same angle as previous + 180
degrees
500 Same angle as next + 180 degrees
cutpos 10 Start
20 Middle
30 End
40 Entry to cut
50 Exit from cut
cuttyp 1 Zigzag
2 One way
3 Circular
4 Swarf
9 Control flags cur_cflg See Control Flags Parameter
10 Surface normal p_svec
vector
11 Surface normal q_svec
vector
12 Surface normal r_svec
vector
* These are maintained for compatability only. Use the Control Flags Parameter instead!

6-20 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

W 30, or 31 (Linear Move, 4-axis Direct)


g
1 2 3 4 5 6 7 8 9

g 30 Direct 4-axis upper gcode


guide – linear move
at rapid
31 Direct 4-axis upper gcode
guide – linear move
at feed rate
1 Wire compensation cc, 0 Wire compensation modal
ccomp (no change)
40 Cancel wire compensation in the
control
41 Wire compensation in the control
= left
42 Wire compensation in the control
= right
140 Cancel wire compensation last
move in the contour
2 X position wx
3 Y position wy
4 Z position wz
5 Feed rate wfr Positive Feed rate in units per minute
-1 Unchanged
6 Wire taper wtpr
7 Corner type wcor 0 Conical
1 Sharp
2 Constant
3 Other
4 Fixed
5 Fishtail
8 Control flags cur_cflg See Control Flags Parameter
9 Corner type radius wcor_rad

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-21


Chapter 6 The NCI File Volume 3

W 11 (4-Axis Taper Move)


g
1 2 3 4 5 6 7 8 9

g 11 gcode
1 Wire compensation cc, Wire compensation modal
0
ccomp (no change)
40 Cancel wire compensation in the
control
41 Wire compensation in the control
= left
42 Wire compensation in the control
= right
140 Cancel wire compensation last
move in the contour
2 X position xnci, x lower point
3 Y position ynci,y lower point
4 Z position znci,z lower point
5 U position u upper point
6 V position v upper point
7 W position w upper point
8 Feed rate fr Feed rate
9 Control flags cur_cflg See Control Flags Parameter

6-22 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

W 32, or 33 (Arc Move, 4-axis Direct)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14

g 32 Direct 4-axis upper gcode


guide – arc move
clockwise
33 Direct 4-axis upper gcode
guide – arc move
counterclockwise
1 (Not used)
2 Wire compensation cc, 0 Wire compensation modal
ccomp (no change)
40 Cancel wire compensation in the
control
41 Wire compensation in the control
= left
42 Wire compensation in the control
= right
140 Cancel wire compensation last
move in the contour
3 X position wx
4 Y position wy
5 Absolute X-axis arc wxc (relative to plane)
center
6 Absolute Y-axis arc wyc (relative to plane)
center
7 Z position wz
8 Feed rate wfr Positive Feed rate per minute
-1 Unchanged
9 Wire taper wtpr
10 Corner type wcor 0 Conical
1 Sharp
2 Constant
3 Other
4 Fixed
5 Fishtail
11 Control flags cur_cflg See Control Flags Parameter
12 Corner type radius wcor_rad
13 Arc type warc_cortyp 0 Conical
1 Sharp
2 Constant
3 Other
4 Fixed
5 Fish tail
14 Arc type radius wcor_radius

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-23


Chapter 6 The NCI File Volume 3

L M R W 80 (Cancel Drill / Canned Cycle)


g
blank line

g 80 gcode

Note: Even though Gcode 80 has no parameters, a blank line must be output for the second line.

6-24 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L 81 (Start Canned Cycle)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19

g 81 gcode
1 Drill cycle type drillcyc 0 Simple
1 Peck
2 Chip break
3 Tap
4 Bore #1
5 Bore #2
6 Misc #1
7 Misc #2
8-19 Custom cycles
2 Z position* znci, z
3 X position* xnci, x
4 (Not used) depth
5 Dwell time dwell
6 Feed rate frplunge
7 First peck peck1
amount
8 Subsequent peck2
peck amount
9 Peck clearance peckclr
10 Chip break retr
retract
11 Drill cycle initial initht
height
12 Drill cycle refht
reference height
13 Drill depth zdrl
14 Boring bar shftdrl
clearance shift
amount
15 W position** w
16 U position** u
17 (Not used)
18 Control flags cur_cflg See Control Flags Parameter
19 Drill depth rev_drl5 1 Indicates reversal of the drill
direction from UVW to XYZ.
*XZ is a 2D point that represents the drill point at the bottom of the hole.
**UW is a 2D point that represents the initial height point.

Note: If vers_no is 8 or greater, the following data is calculated and overwrites the parameters
passed in the NCI:

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-25


Chapter 6 The NCI File Volume 3

depth from z
zdrl (calculated) from w – initht
refht from zdrl (calculated) + refht
tosz (top of stock) from zdrl (calculated) + zdrl (original)
initht from w
xdrl from x

See Volume 1, Working with Drill Cycles.

6-26 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

M R 81 (Start Drill Cycle)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19

g 81 gcode
1 Drill cycle type drillcyc 0 Simple
1 Peck
2 Chip break
3 Tap
4 Bore #1
5 Bore #2
6 Misc #1
7 Misc #2
8-19 Custom cycles
2 X position* xnci, x
3 Y position* ynci, y
4 Z position* znci, depth
5 Dwell time dwell
6 Feed rate frplunge
7 First peck peck1
amount
8 Subsequent peck2
peck amount
9 Peck clearance peckclr
10 Chip break retr
retract
11 Drill cycle initial initht
height
12 Drill cycle refht
reference height
13 Drill depth zdrl
14 Boring bar shftdrl
clearance shift
amount
15 U position** u
16 V position** v
17 W position** w
18 Control flags cur_cflg See Control Flags Parameter
19 Drill depth rev_drl5 1 Indicates reversal of the drill
direction from UVW to XYZ.
*XYZ is a 3D point that represents the drill point at the bottom of the hole.
**UVW is a 3D point that represents the initial height point.

Note: If vers_no is 8 or greater, the following data is calculated and overwrites the parameters
passed in the NCI:

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-27


Chapter 6 The NCI File Volume 3

depth from z
zdrl (calculated) from w – initht
refht from zdrl (calculated) + refht
tosz (top of stock) from zdrl (calculated) + zdrl (original)
initht from w

See Volume 1, Working with Drill Cycles.

6-28 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

W 81 (Start Canned Cycle)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19

g 81 gcode
1 Drill cycle type cancyc 0-19 Custom cycles
2 X position* xnci, x
3 Y position* ynci, y
4 Z position* znci, z
5 Entered value canned1
6 (Not used)
7 Entered value canned4
8 Entered value canned5
9 Entered value canned6
10 Entered value canned7
11 Entered value canned2
12 Entered value canned3
13 (Not used)
14 (Not used)
15 (Not used)
16 (Not used)
17 (Not used)
18 Control flags cur_cflg See Control Flags Parameter
19 (Not used)
*XYZ is a 3D point that represents the drill point at the bottom of the hole.

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-29


Chapter 6 The NCI File Volume 3

L M R W 82 (Additional Drill / Canned Cycle Parameters)


g
1 2 3 4 5 6 7 8 9 10

g 82 gcode
1 Drill parameter 1 drl_prm1
2 Drill parameter 2 drl_prm2
3 Drill parameter 3 drl_prm3
4 Drill parameter 4 drl_prm4
5 Drill parameter 5 drl_prm5
6 Drill parameter 6 drl_prm6
7 Drill parameter 7 drl_prm7
8 Drill parameter 8 drl_prm8
9 Drill parameter 9 drl_prm9
10 Drill parameter 10 drl_prm10

Note: The drl_prm variables do not have a specific meaning; they are values that the post
customization file can use for whatever purpose needed for that cycle.
See Volume 1, Working with Drill Cycles.

6-30 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

R 83 (Block Drill / Canned Cycle Parameters)


g
1 2 3 4 5 6 7 8 9 10 11 12

g 83 gcode
1 Lead drill at depth - X bdrl_x
2 Lead drill at depth - Y bdrl_y
3 Lead drill at depth - Z bdrl_z
4 Distance of drill hole bdrl_ofs_x
minus lead drill
position - X
5 Distance of drill hole bdrl_ofs_y
minus lead drill
position - Y
6 Distance of drill hole bdrl_ofs_z
minus lead drill
position - Z
7 Group number bdrl_tool_grp
8 Work offset for drill bdrl_wrk_ofs
position
9 Position of lead drill bdrl_u
at initial height - X
10 Position of lead drill bdrl_v
at initial height – Y
11 Position of lead drill bdrl_w
at initial height – Z
12 Bitwise tool number, bdrl_tool_no – In this parameter, the data stored in
first head bdrl_tool_no9 “bitwise” format. TEN separate post
variables are extracted from it.
bdrl_tool_no, bdrl_tool_no2,
bdrl_tool_no3, through
bdrl_tool_no9

Note: The G83 NCI data is ONLY written by the Mastercam ROUTER product.

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-31


Chapter 6 The NCI File Volume 3

M R 100 (Canned Cycle Repeat Position)


g
1 2 3 4 5 6 7 8 9 10 11 12 13

g 100 gcode
1 (Not used)
2 X position* xnci, x
3 Y position* ynci, y
4 Z position* znci, z
5 Drill cycle refht
reference height
6 Drill depth zdrl
7 Dwell time dwell
8 Feed rate frplunge
9 U position** u
10 V position** v
11 W position** w
12 Control flags cur_cflg See Control Flags Parameter
13 Drill depth rev_drl5 When 1, indicates reversal of the
drill direction from UVW to XYZ.
*XYZ is a 3D point that represents the drill point at the bottom of the hole.
**UVW is a 3D point that represents the initial height point.

See Volume 1, Working with Drill Cycles.

6-32 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

W 100 (Canned Cycle Repeat Position)


g
1 2 3 4 5

g 100 gcode
1 (Not used)
2 X position xnci, x
3 Y position ynci, y
4 Z position znci, z
5 (Not used)

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-33


Chapter 6 The NCI File Volume 3

L 200 (Threading Parameters One)


Always appears together with the Gcode 201.
g
1 2 3 4 5 6 7 8

g 200 gcode
1 Number of spring nspring
cuts
2 Finish allowance thdfinish
3 Anticipated thread thdpulloff
pull-off
4 Number of starts nstarts
5 Clearance thdxclr
perpendicular to
cuts
6 Thread infeed thdangle Value in radians
angle
7 Equal depth thdequcut 0 Determine depth cuts from:
thread cuts Equal area method.
1 Determine depth cuts from:
Number of cuts.
8 Number of cuts thdncuts >0 Determine number of cuts from:
Number of cuts.

6-34 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L 201 (Threading Parameters Two)


Always appears together with the Gcode 200.
g
1 2 3 4 5 6 7 8 9 10 11 12

g 201 gcode

1 X position 1 thdx1 Thread major


2 X position 2 thdx2 Thread minor
3 Z position 1 thdz1 Starting Z position of thread
4 Z position 2) thdz2 Ending Z position of thread
5 Lead settings thdlead Positive Lead in units per thread
Negative Lead in threads per inch*
6 Amount of first cut thdfirst Calculated based on thdequcut
7 Amount of last cut thdlast
8 Stock clearance in thdzclr Acceleration clearance
Z
9 Thread angle thda1 Value in radians
10 Thread included thda2 Value in radians
angle
11 Thread type thdtype
settings 0 Long cycle (pg32)
1 Canned (pg76)
2 Long cycle (pg92)
12 X position 3 thdx3 Ending X position of thread**

*thdlead is always converted to a (positive) units-per-thread value.


**Calculate thread taper by (thdx2 – thdx3).

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-35


Chapter 6 The NCI File Volume 3

L 900 (Stock Transfer – Misc Ops function)


g
1 2 3 4 5 6 7 8 9 10 11

g 900 gcode

1 Active spindle for stck_spindle 0 Main spindle


stock to transfer 1 Sub spindle
2 stck_init_z Z coordinate on stock to be
transferred
3 stck_final_z Z coordinate on transferred stock
4 stck_chuk_st_z Source chuck Z axis reference
position before transfer
5 stck_chuk_st_x Source chuck X axis reference
position before transfer
6 stck_chuk_end_z Source chuck Z axis reference
position after transfer
7 stck_chuk_end_x Source chuck X axis reference
position after transfer
8 stck_chuk_st_dz Destination chuck Z axis reference
position before transfer
9 stck_chuk_st_dx Destination chuck X axis reference
position before transfer
10 stck_chuk_end_dz Destination chuck Z axis reference
position after transfer
11 stck_chuk_end_dx Destination chuck X axis reference
position after transfer

Processed by postblock pstck_trans. (See Volume 3, Postblocks.)

6-36 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L 901 (Stock Flip – Misc Ops function)


g
1 2 3 4 5 6 7

g 901 gcode

1 Active spindle for stck_spindle 0 Main spindle


stock to transfer
1 Sub spindle
2 stck_init_z Z coordinate on stock before flip
3 stck_final_z Z coordinate on stock after flip
4 stck_chuk_st_z Chuck Z axis position before flip
5 stck_chuk_st_x Chuck X axis position before flip
6 stck_chuk_end_z Chuck Z axis position after flip
7 stck_chuk_end_x Chuck X axis position after flip

Processed by postblock pstck_flip. (See Volume 3, Postblocks.)

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-37


Chapter 6 The NCI File Volume 3

L 902 (Stock Advance – Misc Ops function)


g
1 2 3 4 5 6 7 8 9 10 11 12

g 902 gcode

1 Active spindle for stck_spindle 0 Main spindle


stock to transfer 1 Sub spindle
2 stck_op 0 Push stock
1 Push stock with Use Tool Stop option
2 Pull stock
3 stck_clear Stock clearance (pull stock method)
4 stck_grip Grip length (pull stock method)
5 stck_init_z Z coordinate of stock before advance
6 stck_final_z Z coordinate of stock after advance
7 stck_appr_fr Feed rate that the bar puller uses
while moving into position
8 stck_adv_fr Feed rate that the stock
advances at
9 stck_chuk_st_z Chuck Z axis position before advance
10 stck_chuk_st_x Chuck X axis position before advance
11 stck_chuk_end_z Chuck Z axis position after advance
12 stck_chuk_end_x Chuck X axis position after advance

Processed by postblock pstck_bar_fd. (See Volume 3, Postblocks.)

6-38 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L 903 (Chuck – Misc Ops function)


g
1 2 3 4 5 6
g 903 gcode

1 Active spindle for clmp_spindle 0 main spindle


clamp/unclamp 1 Sub spindle
2 Operation clmp_op 0 Clamp
1 Un-clamp
2 Re-position
3 stck_chuk_st_z Original Z axis Chuck Position
4 stck_chuk_st_x Original X axis Chuck Position
5 stck_chuk_end_z Final Z axis Chuck Position
6 stck_chuk_end_x Final X axis Chuck Position

Processed by postblock pchuck. (See Volume 3, Postblocks.)

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-39


Chapter 6 The NCI File Volume 3

L 904 (TailStock – Misc Ops function)


g
1 2 3
g 904 gcode

1 Operation tlstck_on 0 Retract tailstock


1 Engage tailstock
2 stck_init_z Initial Z position of tailstock
3 stck_final_x Final Z position of tailstock

Processed by postblock ptailstock. (See Volume 3, Postblocks.)

6-40 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L 905 (SteadyRest – Misc Ops function)


g
1 2
g 905 gcode

1 stck_init_z Initial steady rest position


2 stck_final_z Final steady rest position

Processed by postblock psteadyrest. (See Volume 3, Postblocks.)

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-41


Chapter 6 The NCI File Volume 3

L 911 (Define Misc Ops custom parameters Reals)


g
1 2 3 4 5 6 7 8 9 10

g 911 gcode
1 Miscellaneous real 1 miscops_mr1
2 Miscellaneous real 2 miscops_mr2
3 Miscellaneous real 3 miscops_mr3
4 Miscellaneous real 4 miscops_mr4
5 Miscellaneous real 5 miscops_mr5
6 Miscellaneous real 6 miscops_mr6
7 Miscellaneous real 7 miscops_mr7
8 Miscellaneous real 8 miscops_mr8
9 Miscellaneous real 9 miscops_mr9
10 Miscellaneous real 10 miscops_mr10

6-42 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L 912 (Define Misc Ops custom parameters Integers)


g
1 2 3 4 5 6 7 8 9 10

g 912 gcode
1 Miscellaneous integer 1 miscops_mi1
2 Miscellaneous integer 2 miscops_mi2
3 Miscellaneous integer 3 miscops_mi3
4 Miscellaneous integer 4 miscops_mi4
5 Miscellaneous integer 5 miscops_mi5
6 Miscellaneous integer 6 miscops_mi6
7 Miscellaneous integer 7 miscops_mi7
8 Miscellaneous integer 8 miscops_mi8
9 Miscellaneous integer 9 miscops_mi9
10 Miscellaneous integer 10 miscops_mi10

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-43


Chapter 6 The NCI File Volume 3

L 1000, 1001,or 1002 (Tool Change)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18

g 1000 Null tool change gcode


1001 Start-of-file tool gcode
change
1002 Tool change gcode
1 Program number progno
2 Starting sequence seqno
number
3 Sequence number seqinc
increment
4 Tool number t
5 Tool diameter tloffno
offset number
6 Maximum spindle maxss
speed
7 Tool orientation orient
8 Spindle speed ss Positive Spindle speed in RPM
0 Spindle stop
Negative Spindle speed in surface units per
minute
9 Feed rate fr Positive Feed rate in units per minute
Negative Feed rate in units per revolution
10 Coolant use coolant 0 Off
1 Flood
2 Mist
3 Tool
11 X rapid position xr
12 Y rapid position yr
13 Z rapid position zr
14 X home position xh
15 Y home position yh
16 Z home position zh
17 Spindle direction spdir 1 Spindle forward
0 Spindle stop
-1 Spindle reverse
18 (Not used)

Also see “Additional calculated variables” in Volume 1, The NCI File.

6-44 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

M R 1000, 1001, or 1002 (Tool Change)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18

g 1000 Null tool change gcode


1001 Start-of-file tool gcode
change
1002 Tool change gcode
1 Program number progno
2 Starting sequence seqno
number
3 Sequence number seqinc
increment
4 Tool number t
5 Tool diameter tloffno
offset number
6 Tool length offset tlngno
number
7 Plane position plane 0 XY plane
1 YZ plane
2 XZ plane
8 Spindle speed in ss
Positive Spindle forward
RPM
0 Spindle stop
Negative Spindle reverse
9 Feed rate fr
10 Coolant use coolant 0 Off
1 Flood
2 Mist
3 Tool
11 X rapid position xr
12 Y rapid position yr
13 Z rapid position zr
14 X home position xh
15 Y home position yh
16 Z home position zh
17 Axis substitution rotaxis -2 Axis substitution, substitute Y,
CCW
Axis substitution, substitute X,
-1
CCW
0 None
1 Axis substitution, substitute X, CW
2 Axis substitution, substitute Y, CW
11 Polar conversion, rotate about X
12 Polar conversion, rotate about Y

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-45


Chapter 6 The NCI File Volume 3

13 Polar conversion, rotate about Z


21 4-axis, rotate about X
22 4-axis, rotate about Y
23 4-axis, rotate about Z
18 Diameter for axis rotdia
substitution

Also see “Additional calculated variables” in Volume 1, The NCI File.

6-46 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

W 1000, 1001, or 1002 (Tool Change)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22

g 1000 Null tool change gcode


1001 Start-of-file tool gcode
change
1002 Tool change gcode
1 Program number progno
2 Starting sequence seqno
number
3 Sequence number seqinc
increment
4 Cut pass pass
5 Condition code ccode
6 Offset number offset
7 (Not used)
8 Initial wire taper inittaper Positive Taper, right
0 No taper
Negative Taper, left
9 Feed rate fr
10 Flushing water 0 Off
1 Flood
2 Other
11 X thread position threadx
12 Y thread position thready
13 Z thread position threadx
14 X start position startx
15 Y start position starty
16 Z start position startz
17 Height of XY plane xyheight
18 Height of UV plane uvheight
19 X skewed wire thread up_st_vecx
20 Y skewed wire thread up_st_vecy
21 Z skewed wire thread up_st_vecz
22 Skewed wire thread up_st_mode 0 Off
1 Apply to thread
2 Apply to cut
3 Apply to both thread/cut

Also see “Additional calculated variables” in Volume 1, The NCI File.

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-47


Chapter 6 The NCI File Volume 3

L 1003 (End of File)


g
1 2 3

g 1003 gcode
1 X home position xh
2 (Not used)
3 Z home position zh

6-48 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

M R 1003 (End of File)


g
1 2 3

g 1003 gcode
1 X home position xh
2 Y home position yh
3 Z home position zh

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-49


Chapter 6 The NCI File Volume 3

W 1003 (End of File)


g
1 2 3

g 1003 gcode
1 X thread position threadx
2 Y thread position thready
3 Z thread position threadz

6-50 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L M R W 1004 (Cancel Cutter Compensation)


g
blank line

g 1004 gcode

Note: Even though Gcode 1004 has no parameters, a blank line must be output for the second line.

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-51


Chapter 6 The NCI File Volume 3

L M R W 1005, 1006, 1007, 1008 (Manual Entry / Tool Comment)


g
comment

g 1005 Comment (before)


1006 Comment (after)
1007 Comment (with)
1008 Tool operation comment
Comment Text to be inserted into
the NC program

See Volume 1, Posting Comments into the NC File.

6-52 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

W 1009 (Wire Cut Length)


g
1 2 3

g 1009 Cut Length gcode


1 Wirepath cut length cutlength
2 (Not used)
3 (Not used)

Note: This NCI Gcode does not appear in the Wire V8 NCI file, although it may be included in future releases.

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-53


Chapter 6 The NCI File Volume 3

W 1010 (Wire Condition Change)


g
1 2 3 4 5 6 7 8 9 1011 12 13 14

g 1010 gcode
1 Wire compensation cc 0 Cutter compensation modal
(no change)
40 Cancel cutter compensation in the
control
41 Cutter compensation in the control
= left
42 Cutter compensation in the control
= right
140 Cancel cutter compensation last
move in the contour
2 Condition code ccode
3 Wire offset offset
4 Wire diameter tldia
5 Register value 1 reg1
6 Register value 2 reg2
7 Register value 3 reg3
8 Register value 4 reg4
9 Register value 5 reg5
10 Register value 6 reg6
11 Register value 7 reg7
12 Register value 8 reg8
13 Register value 9 reg9
14 Register value 10 reg10

6-54 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L M R W 1011 (Define Miscellaneous Reals)


g
1 2 3 4 5 6 7 8 9 10

g 1011 gcode
1 Miscellaneous real 1 mr1
2 Miscellaneous real 2 mr2
3 Miscellaneous real 3 mr3
4 Miscellaneous real 4 mr4
5 Miscellaneous real 5 mr5
6 Miscellaneous real 6 mr6
7 Miscellaneous real 7 mr7
8 Miscellaneous real 8 mr8
9 Miscellaneous real 9 mr9
10 Miscellaneous real 10 mr10

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-55


Chapter 6 The NCI File Volume 3

L M R W 1012 (Define Miscellaneous Integers)


g
1 2 3 4 5 6 7 8 9 10

g 1012 gcode
1 Miscellaneous integer 1 mi1
2 Miscellaneous integer 2 mi2
3 Miscellaneous integer 3 mi3
4 Miscellaneous integer 4 mi4
5 Miscellaneous integer 5 mi5
6 Miscellaneous integer 6 mi6
7 Miscellaneous integer 7 mi7
8 Miscellaneous integer 8 mi8
9 Miscellaneous integer 9 mi9
10 Miscellaneous integer 10 mi10

6-56 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L 1013 (Define Miscellaneous Parameters)


g
1 2 3 4 5 6 7 8 9 10

g 1013 gcode
1 Cutter cc
0 Cutter compensation modal
compensation
40 Cancel cutter compensation in the
control
41 Cutter compensation in the control
= left
42 Cutter compensation in the control
= right
140 Cancel cutter compensation last
move in the contour
2 Tool corner tcr Tool nose radius or
raidus tool radius of drill type tool
3 Tool diameter tldia Always 0
4 (Not used)
5 (Not used)
6 X coordinate of tox (relative to view)
tool plane origin
7 Y coordinate of toy (relative to view)
tool plane origin
8 X coordinate of toz (relative to view)
tool plane origin
9 Operation code opcode 101 Rough
102 Finish
103 Groove
104 Thread
105 Drill
106 Point
10 Tool library path strtool,
and name* strtoolpath

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-57


Chapter 6 The NCI File Volume 3

M R 1013 (Define Miscellaneous Parameters)


g
1 2 3 4 5 6 7 8 9 10

g 1013 gcode
1 Cutter
compensation cc 0 Cutter compensation modal
use
40 Cancel cutter compensation in the
control
41 Cutter compensation in the control
= left
42 Cutter compensation in the control
= right
140 Cancel cutter compensation last
move in the contour
2 Tool diameter tldia
3 Tool corner tcr
radius
4 Depth values to 0 Center
center or tip cctotip
setting 1 Tip

5 View number tlplnno 0 No matrix


1 Top
2 Front
3 Back
4 Bottom
5 Right side
6 Left side
7 Isometric
8 Axonometric
6 X coordinate of tox (relative to view)
tool plane origin
7 Y coordinate of toy (relative to view)
tool plane origin
8 Z coordinate of toz (relative to view)
tool plane origin

9 Operation code opcode 1 2D contour


2 3D contour
3 Drill
4 Pocket
5 Ruled
6 2D swept
7 3D swept
8 Revolution

6-58 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

9 Loft
10 Coons
11 Fillet
12 Flowline
13 Multisurface finish
14 Multisurface rough
15 Point
16 Drill 5-axis
17 Swarf 5-axis
18 Curve 5-axis
19 Facing
10 Tool reference strtool,
path and name* strtoolpath

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-59


Chapter 6 The NCI File Volume 3

W 1013 (Define Miscellaneous Parameters)


g
1 2 3 4 5 6 7 8 9 10

g 1013 gcode
1 Cutter
compensation cc 0 Cutter compensation modal
use
40 Cancel cutter compensation in the
control
41 Cutter compensation in the control
= left
42 Cutter compensation in the control
= right
140 Cancel cutter compensation last
move in the contour
2 Tool (wire) tldia
diameter
3 Tool (wire) tlrad
radius
4 Overburn
overburn
amount
5 Wire status wire 0 Off
1 On
6 Power status power 0 Off
1 On
7 Work origin X wox

8 Work origin y woy


9 Operation code opcode 201 Contour
202 Contour
203 Canned (Drill)
204 No Core
205 4-axis taper, no skim
206 2D reverse skimcut
207 (Not used)
208 4-axis direct, reverse skimcuts
209 4-axis direct, no skimcuts
210 4-axis taper, reverse skimcuts
211 4-axis taper, one-way skimcuts
212 4-axis direct, one-way skimcuts
213 2D one-way skimcuts
214 Rapid point
10 Power library strtool, Full ‘path&name’ of the power
path and name strtoolpath library used for the operation

6-60 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L M R W 1014 (Tool Plane View Matrix)


g
1 2 3 4 5 6 7 8 9

g 1014 gcode
1 X vector X in WCS m1
2 X vector Y in WCS m2
3 X vector Z in WCS m3
4 Y vector X in WCS m4
5 Y vector Y in WCS m5
6 Y vector Z in WCS m6
7 Z vector X in WCS m7
8 Z vector Y in WCS m8
9 Z vector Z in WCS m9

View xx xy xz yx yy yz zx zy zz
Top (1) 1 0 0 0 1 0 0 0 1
Front (2) 1 0 0 0 0 1 0 -1 0
Back (3) -1 0 0 0 0 1 0 1 0
Bottom (4) -1 0 0 0 1 0 0 0 -1
Right Side (5) 0 1 0 0 0 1 1 0 0
Left Side (6) 0 -1 0 0 0 1 -1 0 0
Isometric (7) 0.7071 0.7071 0 -0.4082 0.4082 0.8165 0.5774 -0.5774 0.5773
Axonometric (8) 0.5 -0.8536 0.1464 0.5 0.1464 0.8536 0.7071 0.5 0.5
Variable Name m1 m2 m3 m4 m5 m6 m7 m8 m9

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-61


Chapter 6 The NCI File Volume 3

W 1015 (Subroutine Parameters)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20

g 1015 gcode
1 Subroutine type settings subtyp 0 Not a subroutine
1 Write subroutine
2 Call subroutine only
2 Subroutine number subno
3 Thread/cut flag td_ct_flg 0 No thread or cut
(Not used) 1 Allow thread the wire
in V8.1 2 Allow cut the wire
4 Tab cut tabcut 0 No tab cut
1 Tab cut
2 Contour with tab cut
5 Wire trim (wtrim) 0 Trim in control
1 Trim in computer
2 3D tracking
6 Skimcut options skimpass 0 No skimcut
+1 First skim cut pass on
a contour
-1 Subsequent skim cut
pass on a contour
-2 Last skim cut pass on
a contour
7 Wire cut position X cutx
8 Wire cut position Y cuty
9 XY trimming plane trimplane1
10 UV trimming plane trimplane2
11 Register value 1 reg1
12 Register value 2 reg2
13 Register value 3 reg3
14 Register value 4 reg4
15 Register value 5 reg5
16 Register value 6 reg6
17 Register value 7 reg7
18 Register value 8 reg8
19 Register value 9 reg9
20 Register value 10 reg10

6-62 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L 1016 (Additional Miscellaneous Parameters)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17

g 1016 gcode
1 Operation id op_id
2 Tool type tool_typ
3 Internal toolpath tool_op
opcode 60 Rough
61 Finish
62 Grooving
63 Threading
64 Drill
65 Point
66 Facing
67 Cutoff
68 Plunge rough
69 Manual entry
70 Merged ASCII
201 Canned finish
202 Canned rough
203 Canned rough and finish
204 Canned rough face
205 Canned rough and finish face
206 Canned pattern repeat rough
207 Canned pattern repeat rough and
finish
208 Canned groove rough
209 Canned groove finish
210 Quick rough
211 Quick finish
212 Quick groove
4 Construction cplnno
view number
5 X coordinate of corgx (relative to view)
construction
plane origin

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-63


Chapter 6 The NCI File Volume 3

6 Y coordinate of corgy (relative to view)


construction plane
origin
7 X coordinate of corgz (relative to view)
construction plane
origin
8 Cutter cc_computer 0 Off
compensation in 41 Left
computer setting
42 Right
9 Work offset number workofs
10 Metric is used met_tool
11 Number of flutes on n_flutes
cutter
12 Active spindle spindle_no 0 Main spindle
1 Sub spindle
13 Number of threads n_tap_thds
on tap
14 Station number lstation (Not used)
15 Upper turret used? lturret 0 No
1 Yes
16 Unique tool ID lathe ltool_id
17 Operation ID Source_op_id In transform operations, the
xform_op_id op_id is set to the operatioon ID
of the source operation. The
transform operation ID is set in
xform_op_id.

6-64 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

M R 1016 (Additional Miscellaneous Parameters)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17

g 1016 gcode
1 Operation id op_id
2 Tool type tool_typ
3 Internal toolpath tool_op
opcode 1 Contour
2 Drill
3 Pocket
4 Version 7 linear array,
Version 8 mirror, rotate, translate
5 Multisurface rough parallel
6 Multisurface rough radial
7 Multisurface rough project
8 Multisurface rough flowline
9 Multisurface rough contour
10 Multisurface rough pocket
11 Multisurface finish parallel
12 Multisurface finish radial
13 Multisurface finish project
14 Multisurface finish flowline
15 Multisurface finish contour
16 For C-Hook- created operations
17 Manual entry
18 Version 8
19 Point
20 Trimmed
21 Ruled
22 Revolved
23 Letters
24 Swept 2D
25 Swept 3D
26 Coons
27 Lofted
28 5-axis drilling
29 5-axis curve
30 Project toolpath onto a plane
31 Project toolpath onto a cylinder
32 Project toolpath onto a sphere
33 Project toolpath onto a cone
34 Project toolpath onto a cross
section
35 Project toolpath onto a surface
November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-65
Chapter 6 The NCI File Volume 3

36 Non-associative contour
37 Non-associative drilling
38 Non-associative pocketing
39 Multisurface finish pencil trace
40 Multisurface finish leftover stock
41 Multisurface finish steep
42 Multisurface finish shallow
43 Multisurface finish constant scallop
44 Multisurface rough plunge
45 Multisurface finish 5-axis flowline
46 Multisurface finish 4-axis
47 Merged in ASCII NCI
48 5-axis swarf
49 5-axis roll die
51 Face contouring
52 Cross contouring
53 C-axis contouring
54 Non-associative drilling (not used)
55 Face drilling
56 Cross drilling
57 C-axis drilling
100 Thread mill
101 Edit common operation parameters
102 Facing
4 Construction cplnno
view number
5 X coordinate of corgx (relative to view)
construction
plane origin

6 Y coordinate of corgy (relative to view)


construction
plane origin
7 X coordinate of corgz (relative to view)
construction
plane origin
8 Cutter cc_computer 0 Off
compensation in 41 Left
computer
42 Right
9 Work offset workofs
number
10 Metric is used met_tool
11 Number of flutes n_flutes
on cutter

6-66 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

12 Active spindle spindle_no


for lathe
13 Number of n_tap_thds
threads on tap
14 Station number lstation (Head #)
15 Upper turret is lturret
used
16 Unique tool ID ltool_id
17 Operation ID xform_op_id If the operation is a transform
operation, this is the operation ID of
the transformed operation.

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-67


Chapter 6 The NCI File Volume 3

W 1016 (Additional Miscellaneous Parameters)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17

g 1016 gcode
1 Operation id op_id
2 Finish spawned nocore_fin
from Nocore
3 Internal toolpath tool_op
opcode 74 Contour
75 Canned
76 No Core
77 Manual entry
78 Point
79 4-axis
80 Transform
4 Construction cplnno
view number
5 X coordinate of corgx (relative to view)
construction
plane origin
6 Y coordinate of corgy (relative to view)
construction
plane origin
7 X coordinate of corgz (relative to view)
construction
plane origin
8 Cutter cc_computer 0 Off
compensation in 41 Left
computer
42 Right
9 Work offset workofs
number
10 Metric is used met_tool
11 Punch, die, open pdo_type
flag 0 Punch
1 Die
2 Open
12 spindle_no
13 rpd_hght
14 landheight
15 Contour type contour_typ 0, 1, 2, 3, 4 (left to right)
button selected
16 Chain height contour_pos 0 XY height
button selected
1 Land height

2 UV height

6-68 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

17 (Not used)

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-69


Chapter 6 The NCI File Volume 3

L M R 1017 (Construction Plane View Matrix)


g
1 2 3 4 5 6 7 8 9

g 1017 gcode
1 X vector X in WCS cm1
2 X vector Y in WCS cm2
3 X vector Z in WCS cm3
4 Y vector X in WCS cm4
5 Y vector Y in WCS cm5
6 Y vector Z in WCS cm6
7 Z vector X in WCS cm7
8 Z vector Y in WCS cm8
9 Z vector Z in WCS cm9

6-70 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L M R 1018 (Subprogram Start Definition)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27

g 1018 gcode
1 Subprogram number sub_op_id
2 Actual operation id sub_grp_id
3 Transform / non- sub_ref_id 0 Non-transform
tansform indicator
>0 Transform
4 Iteration counter sub_sec_no Transform operations:
<0 = Off
0 = Original
>0 = Copy
Non-transform operations:
<1 = Copy in transform
1 = Original
>1 = Copy
5 Total number of sub_totl_no
instances (1-based)
6 (Not used) sub_chn no
7 Absolute or sub_inc 0 Absolute
incremental 1 Incremental
8 Transform type sub_trnstyp 0 Mirror
1 Rotate
2 Scale (not used)
3 Translate
9 sub_trnmthd 0 Translate method = Tool plane
1 Translate method = Tool plane with “Tool
plane origin ONLY” checked

2 Translate method = Coordinate

10 Transform matrix sub_m1


11 Transform matrix sub_m2
12 Transform matrix sub_m3
13 Transform matrix sub_m4
14 Transform matrix sub_m5
15 Transform matrix sub_m6
16 Transform matrix sub_m7
17 Transform matrix sub_m8
18 Transform matrix sub_m9

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-71


Chapter 6 The NCI File Volume 3

19 Transform X data Mirrored data:


X-axis mirror. Set X-axis intersection.
Rotated data:
XYZ = center of rotation relative to current view.
Translated data:
XYZ = translation distance relative to original
operation.
20 Transform Y data sub_trnsy Mirrored data:
Y-axis mirror. Set Y-axis intersection.
Rotated data:
XYZ = center of rotation relative to current view
Translated data:
XYZ = translation distance relative to original
operation.
21 Transform Z data sub_trnsz Rotated data:
XYZ = center of rotation relative to current view
Translated data:
XYZ = translation distance relative to original
operation
22 First tool in the sub_nxt_t
transform group
23 First head number in sub_nxt_h
the transform group
24 (Not used) sub_nxt_tid
25 More than one tool in sub_mny_t 0 Only one tool used in the transform
transform 1 Multiple tools used in the transform
26 (Internal Use) 1 Source
2 Source path
10 One level call
100 Separate subs
1000 All Incremenal
27 (Internal Use) Flags if it is OK to write the 1018 line

For Mil and Ruter, see Volume 2, How Subprograms Work.


For Lathe, see Volume 2, How Lathe Canned Cycles Work.

6-72 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L M R 1019 (Subprogram End Definition)


g
1 2 3 4 5 6

g 1019 gcode
1 Subprogram esub_op_id
number
2 Actual operation esub_grp_id
id
3 Transform / non- esub_ref_id 0 Non-transform
transform flag
>0 Transform
4 Iteration counter esub_sec_no Transform operations:
<0 = Off
0 = Original
>0 = Copy
Non-transform operations:
<1 = Copy in transform
1 = Original
>1 = Copy
5 Total number of esub_totl_no
instances
6 (Not used) esub_chn_no

For Mill and Router, see Volume 2, How Subprograms Work.


For Lathe, see Volume 2, How Lathe Canned Cycles Work.

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-73


Chapter 6 The NCI File Volume 3

L 1020 (Stock Parameters)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14

g 1020 gcode
1 Length of stock stck_ht
along Z axis
2 Maximum stck_wdth
diameter of stock
3 Same as 2 stck_thck
4 Center of stock stck_x
along Z axis
5 Center of stock stck_y
6 Center of stock stck_z Always 0
7 Origin corner stck_crnr Always 0
8 Rotary axis in rotary_vecx Always 0
terms of Tplane
9 Rotary axis in rotary_vecy Always 0
terms of Tplane
10 Rotary axis in rotary_vecz Always 0
terms of Tplane
11 (Not used)
12 Parameter file
read flag
(read internally)
13 Maximum spindle maxss
speed
14 Stock material
stck_matl
name

6-74 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

M R 1020 (Stock Parameters)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14

g 1020 gcode
1 X component, stck_ht
width
2 Y component, stck_wdth
height
3 Z component, stck_thck
thickness
4 X origin of block stck_x
5 Y origin of block stck_y
6 Z origin of block stck_z
7 Origin corner stck_crnr 0 Origin corner: top - center
1 Origin corner: top – upper left
2 Origin corner: top – upper right
3 Origin corner: top – lower right
4 Origin corner: top – lower left
5 Origin corner: bottom – upper left
6 Origin corner: bottom – upper right
7 Origin corner: bottom – lower right
8 Origin corner: bottom – lower left
8 Rotary axis in rotary_vecx
terms of Tplane
9 Rotary axis in rotary_vecy
terms of Tplane
10 Rotary axis in rotary_vecz
terms of Tplane
11 (Not used)
12 Parameter file
read flag
(read internally)
13 Maximum spindle maxss
speed
14 String with the
stock material stck_matl
name

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-75


Chapter 6 The NCI File Volume 3

W 1020 (Stock Parameters)


g
1 2 3 4 5 6 7 8 9 10 11 12 13 14

g 1020 gcode
1 X component, stck_ht
width
2 Y component, stck_wdth
height
3 Z component, stck_thck
thickness
4 X origin of block stck_x
5 Y origin of block stck_y
6 Z origin of block stck_z
7 Origin corner stck_crnr 0 Origin corner: top - center
1 Origin corner: top – upper left
2 Origin corner: top – upper right
3 Origin corner: top – lower right
4 Origin corner: top – lower left
5 Origin corner: bottom – upper left
6 Origin corner: bottom – upper right
7 Origin corner: bottom – lower right
8 Origin corner: bottom – lower left
8 (Not used)
9 (Not used)
10 (Not used)
11 Tank fill / empty tank
flag
12 Parameter file
read flag
(read internally)
13 (Not used)
14 String with the
stock material stck_matl
name

6-76 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

L M R W 1025 (Canned Text)


g
1 2 3 4 5 6 7 8 9 10

g 1025 gcode
1 cant_pos1 through cant_pos10 are
Cantext cant_pos1
represented by the 1000s digit,
parameter cant_val1
where:
2 cant_pos2 0nnn Canned text before
cant_val2
3 cant_pos3 1nnn Canned text with
cant_val3
4 cant_pos4 2nnn Canned text after
cant_val4
5 cant_val1 through cant_val10 is a
cant_pos5
value (1-99) extracted from the
cant_val5
lower three nnn digits.
6 cant_pos6
cant_val6
7 cant_pos7
cant_val7
8 cant_pos8
cant_val8
9 cant_pos9
cant_val9
10 cant_pos10
cant_val10

See Volume 1, Working with Canned Text.

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-77


Chapter 6 The NCI File Volume 3

L M R 1027 (Working Coordinate System)

g
1 2 3 4 5 6 7 8 9 10 11 12

g 1027 gcode
1 X vector X in WCS t_wcs_m1
2 X vector Y in WCS t_wcs_m2
3 X vector Z in WCS t_wcs_m3
4 Y vector X in WCS t_wcs_m4
5 Y vector Y in WCS t_wcs_m5
6 Y vector Z in WCS t_wcs_m6
7 Z vector X in WCS t_wcs_m7
8 Z vector Y in WCS t_wcs_m8
9 Z vector Z in WCS t_wcs_m9
10 X-axis origin t_orgin_x
11 Y-axis origin t_orgin_y
12 Z-axis origin t_orgin_z

6-78 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

M R 1028 (Right-angle head data)

g
1 2 3 4 5 6 7 8 9 10 11 1213 14 15 16 17

g 1027 gcode
1 Holder type ra_type 0 No head
1 Right-angle
2 Compound
3 Block drill
2 Offset register ra_offset
3 Tool path pector X ra_vecx
4 Tool path pector Y ra_vecy
5 Tool path vector Z ra_vecz
6 Tool initial vector X ra_svecx
7 Tool initial vector Y ra_svecy
8 Tool initial vector Z ra_svecz
9 Head offset X ra_hvecx
10 Head offset Y ra_hvecy
11 Head offset Z ra_hvecz
12 Tool offset X ra_tvecx
13 Tool offset Y ra_tvecy
14 Tool offset Z ra_tvecz
15 Head number ra_head_no only used for block drilling
16 ra_translated 0 coordinates no translated
1 coordinates are translated to the
machine view
17 ra_rot_head 0 Fixed-head
1 roatry motion in head

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-79


Chapter 6 The NCI File Volume 3

L M R W 1050 (Define NCI Version Header)


g
1 2 3 4 5 6 7 8 9

g 1050 gcode
1 Mastercam major vers_no
version number
2 Mastercam minor m_vers_no
version number
3 MC9 file - day stamp mc_day
4 MC9 file - month stamp mc_mon
5 MC9 file - year stamp mc_year
6 MC9 file - hour stamp mc_hour
7 MC9 file - minute stamp mc_minute
8 MC9 file - second stamp mc_sec
9 MC9 file name smcname

6-80 Mastercam version 9.1 MP Post Reference Guide November 2002


Volume 3 Chapter 6 The NCI File

NC Parameters
Two basic types of NC Parameters can be passed to the post customization file.
You can identify the type that is being passed based on the NCI Gcode range:
Toolpath operation information (NCI Gcodes 10000 through 19999)
Tool information (NCI Gcodes 20000 through 29999)

L M R W 10,000 Series (Toolpath Additional Parameters)


See Volume 3, Parameter Information.

L M R W 20,000 Series (Tool Parameters)


See Volume 3, Parameter Information.

November 2002 Mastercam Version 9.1 MP Post Reference Guide 6-81

You might also like