Each cycle has a unique id which is available through the cycleType
property. All cycles are described by a set of parameters and an ordered set of points (or toolpath). The cycle parameters are available in the property cycle
upon invocation of onCycle().
It is discouraged that you overload the meaning of built-in cycles and parameters. Instead a new cycle or parameter should be introduced.
Well-known cycles that do not have an NC counterpart for a particular control may be expanded by invoking expandCyclePoint()
. expandCyclePoint()
may in return invoke onCommand()
. Some times it is acceptable to map rapid traversal to feed traversal but the oppsosite is not allowed unless it is guaranteed that the cutter cannot come in contact with (or close to) any stock. Note that not all cycles can be expanded into alternative commands and must be implemented in the post configuration to be supported.
setCurrentPosition()
if it is different from the default and possibly add additional motion.The following parameters have been reserved. Note that not all cycles make use of each defined parameter.
clearance
: The clearance plane (absolute coordinate).retract
: The retract plane (absolute coordinate). Rapid motion is allowed from the clearance plane and down to the retract plane). The retract plane defaults to the clearance plane. The retract plane can be ignored if not supported by the control.stock
: The stock plane (absolute coordinate).depth
: The depth below the stock plane. The depth is positive for points below the stock plane.bottom
: The bottom plane (stock - depth).pitch
: The helical pitch (incremental depth per turn).feedrate
: The primary feedrate. Usually specifies the plunging feedrate.retractFeedrate
: The retraction feedrate. Defaults to the primary feedrate if not specified.plungeFeedrate
: The plunge feedrate. Defaults to the primary feedrate if not specified. Note that the primary feedrate (feedrate
) is the plunge feedrate for drilling cycles.stopSpindle
: Stop spindle during positioning/retracting.positioningFeedrate
: The positioning feedrate.positioningSpindleSpeed
: The positioning spindle speed.dwellDepth
: The dwelling depth.dwell
: The dwelling time in seconds.incrementalDepth
: The incremental/pecking depth.incrementalDepthReduction
: The incremental/pecking depth reduction per plunge. Defaults to 0.minimumIncrementalDepth
: The minimum incremental/pecking depth per plunge. Defaults to incrementalDepth
.accumulatedDepth
: Specifies the total plunging depth before forcing full retract to the retract plane.plungesPerRetract
: Specifies the number of plunges per retract (derived from accumulatedDepth
and incrementalDepth
).chipBreakDistance
: Specifies the distance to retract to break the chip. Undefined by default.shift
: Specifies the shifting distance away from the boring wall.shiftOrientation
: Specifies the orientation of the cutter in radians when shifting. Defaults to machineParameters.spindleOrientation.compensatedShiftOrientation
: Specifies the orientation of the spindle in radians when shifting (shiftOrientation - tool.boringBarOrientation).shiftDirection
: Specifies the shift direction in radians when shifting (pi + shiftOrientation).backBoreDistance
: Specifies the back boring distance.diameter
: Specifies the diameter of the hole.stepover
: The maximum stepover between passes.numberOfSteps
: Specifies the number of passes/steps.threading
: Specifies left/right handed thread.direction
: Specifies climb/conventional milling.repeatPass
: Specifies that the final pass should be repeated.compensation
: Specifies that the compensation type. That valid types are computer
, control
, wear
, and inverseWear
.incrementalX
: Specifies the incremental distance along X.incrementalZ
: Specifies the incremental distance along Z.The parameters bottom
, plungesPerRetract
, compensatedShiftOrientation
, and shiftDirection
are calculated by the post processor.
The post processor has built-in support for the following cycles. Please note that the G-codes specified below are only intended for guidance and may not be the proper mapping for a particular control.
The preliminary default motion for a cycle point is as follows:
a) If the initial plane is above the clearance plane:
b) If the initial plane is below the clearance plane:
Defined properties: clearance
, retract
, stock
, depth
, feedrate
Cycle for center drilling, drilling, reaming, and rough boring (G81 style). Same as counter-boring
but without dwelling at the bottom of the hole.
feedrate
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, dwell
Cycle for counter boring, spot drilling, and face drilling (G82 style). Similar to drilling
but dwells at the bottom of the hole.
feedrate
).dwell
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, dwell
, incrementalDepth
, incrementalDepthReduction
, accumulatedDepth
, chipBreakDistance
This cycle is for chip breaking (G73 style). The property machineParameters.chipBreakingDistance
specifies the distance that the machine will retract to break the chips for cycle chip-breaking
. If machineParameters.chipBreakingDistance
is undefined the cycle will use full retracts. When expanding the cycle the property machineParameters.drillingSafeDistance
specifies the safety distance above the remaining stock for which the machine will rapid down (if undefined the cycle will do feed plunging from the clearance plane).
incrementalDepth
) at a time.dwell
).chipBreakDistance
if defined and otherwise machineParameters.chipBreakingDistance
to break chip (or retract to clearance plane if accumulatedDepth
has been reached).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, dwell
, incrementalDepth
, incrementalDepthReduction
, spindleSpeedDwell
This cycle is for deep hole drilling with full retract (G83 style). When expanding the cycle the property machineParameters.drillingSafeDistance
specifies the safety distance above the remaining stock for which the machine will rapid down (if undefined the cycle will do feed plunging from the clearance plane).
incrementalDepth
) at a time.dwell
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, stopSpindle
, breakThroughDistance
, breakThroughFeedrate
, breakThroughSpindleSpeed
, dwell
, stopSpindle
, dwell
, spindleSpeedDwell
This cycle is for breaking through with reduced feed.
feedrate
).breakThroughFeedrate
and breakThroughSpindleSpeed
).dwell
).stopSpindle
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, startingDepth
, stopSpindle
, positioningFeedrate
, positioningSpindleSpeed
, dwellDepth
, dwell
, spindleSpeedDwell
This cycle is for guided deep hole drilling commonly known as gun drilling. This cycle is used for deep drilling with non self-guiding drills.
positioningFeedrate
) and positioning spindle speed (positioningSpindleSpeed
).feedrate
).dwell
).positioningSpindleSpeed
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, dwell
Left-tapping (G74 style).
feedrate
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, dwell
Right-tapping (G84 style). If the feedrate is not specified the feedrate will be set to the tapping feed of the current tool.
feedrate
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, dwell
Left tapping for left tapping tools otherwise right tapping. See left-tapping and right-tapping.
Defined properties: clearance
, retract
, stock
, depth
, feedrate
, incrementalDepth
, incrementalDepthReduction
, accumulatedDepth
, chipBreakDistance
, dwell
Right-tapping with chip breaking. If the feedrate is not specified the feedrate will be set to the tapping feed of the current tool. The property machineParameters.chipBreakingDistance
specifies the distance that the machine will retract to break the chips for the cycle. If machineParameters.chipBreakingDistance
is undefined the cycle will use full retracts. When expanding the cycle the property machineParameters.drillingSafeDistance
specifies the safety distance above the remaining stock for which the machine will rapid down (if undefined the cycle will do feed plunging from the clearance plane).
feedrate
) by no more than the given plunge depth (incrementalDepth
) at a time.chipBreakDistance
is defined and otherwise machineParameters.chipBreakingDistance
to break chip (or retract to clearance plane (or initial plane for last cycle point) if accumulatedDepth
has been reached).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, incrementalDepth
, incrementalDepthReduction
, accumulatedDepth
, chipBreakDistance
Right-tapping with chip breaking. If the feedrate is not specified the feedrate will be set to the tapping feed of the current tool. The property machineParameters.chipBreakingDistance
specifies the distance that the machine will retract to break the chips for the cycle. If machineParameters.chipBreakingDistance
is undefined the cycle will use full retracts. When expanding the cycle the property machineParameters.drillingSafeDistance
specifies the safety distance above the remaining stock for which the machine will rapid down (if undefined the cycle will do feed plunging from the clearance plane).
feedrate
) by no more than the given plunge depth (incrementalDepth
) at a time.chipBreakDistance
is defined and otherwise machineParameters.chipBreakingDistance
to break chip (or retract to clearance plane (or initial plane for last cycle point) if accumulatedDepth
has been reached).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, incrementalDepth
, incrementalDepthReduction
, accumulatedDepth
, chipBreakDistance
Left tapping for left tapping tools otherwise right tapping. See left-tapping-with-chip-breaking and right-tapping-with-chip-breaking.
Defined properties: clearance
, retract
, stock
, depth
, feedrate
, retractFeedrate
This cycle is used to enlarge an existing hole slightly (G85 style).
feedrate
).retractFeedrate
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, dwell
Boring cycle for tighter holes (G86 style). Counter boring for boring bar. This cycle is used to achieve accurate depths.
feedrate
).dwell
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, dwell
, shift
Cycle for fine boring (G76 style).
feedrate
).dwell
).shift
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, dwell
, shift
, shiftOrientation
, backBoreDistance
Back boring (G87 style). The machineParameters.spindleOrientation
will be used when expanding the cycle if shiftOrientation
is undefined. The tool must be compensated to the top of the cutter. You must make sure that there is room for the tool below the given Z-levels.
shift
and shiftOrientation
).feedrate
and backBoreDistance
).feedrate
).shift
and shiftOrientation
).retract
).clearance
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, dwell
Boring cycle with manual retract (G88 style).
feedrate
).dwell
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, retractFeedrate
, dwell
Boring (G89 style).
feedrate
).dwell
).retractFeedrate
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, pitch
, diameter
, direction
, stepover
, numberOfSteps
, repeatPass
, compensation
Bore milling.
feedrate
).feedrate
).feedrate
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, pitch
, diameter
, dwell
, threading
, direction
, stepover
, numberOfSteps
, repeatPass
, compensation
Thread milling.
feedrate
).feedrate
).dwell
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
, plungeFeedrate
, diameter
, stepover
, incrementalDepth
, direction
, repeatPass
Circular pocket milling.
feedrate
) by no more than the given plunge depth (incrementalDepth
) at a time.feedrate
).feedrate
).Defined properties: clearance
, retract
, stock
, depth
, feedrate
Cycle for probing.
feedrate
).Defined properties: clearance
, pitch
, incrementalX
, incrementalZ
Thread turning.
Defined properties: usePartCatcher
, stopSpindle
, feedrate
, spindleSpeed
, dwell
, spindleOrientation
, feedPosition
, chuckPosition
, useMachineFrame
Defined properties: stopSpindle
, spindleSpeed
, feedrate
, pullingDistance
, dwell
Defined properties: stopSpindle
, spindleSpeed
, feedrate
, dwell
, feedPosition
, useMachineFrame
, unclampMode
Where unclampMode
can be keep-clamped
, unclamp-primary
, or unclamp-secondary
.