G-codeCanned CyclesModal group 9Mill

G80: Canned Cycle Cancel

G80 switches off whichever canned cycle is running, G73 and G81 through to G89, and gives the control back to ordinary motion. It carries no addresses of its own. It also throws away the data the cycle was holding, so the retract plane, the depth, the peck and the dwell all have to be written again for the next cycle. A motion code from group 01 does the cancelling just as well, which is exactly why a program with no G80 in it runs clean for a year and then drills a fixture.

Syntax

G80             Cancel the active canned cycle
G80 G00 Z50.    Cancel, then rapid clear, one block

Parameters

G80 takes no addresses. What matters is which of the cycle's settings go with it and which stay live for the next tool.

Cycle dataSurvives G80Notes
R retract planeNoCleared. The next cycle block has to state it again
Z depthNoCleared with the rest of the cycle data
Q peck depthNoHeld as cycle data on G73 and G83, gone after the cancel
P dwellNoSame, on G82 and on a G83 with a pause at depth
F feedYesModal in its own right. The drilling feed is still live on the next cutting block
G98 G99 return levelYesA separate modal group, unchanged by G80
G43 tool length offsetYesGroup 08. Only G49 or a reset clears that

Example

O0009 (BRACKET PLATE, 16MM 6082, 4 HOLES THEN A SLOT)
G21 G17 G40 G49 G80 G90          (safe start block)
T04 M06                          (6.8mm HSS-Co drill, M8 tapping size)
G54
S2300 M03                        (49m/min, 0.12mm/rev)
G00 X15. Y15.                    (first hole, clear of the clamps)
G43 H04 Z25. M08                 (tool length comp on, flood coolant)
G99 G81 Z-18.5 R2. F280          (16mm plate, 2mm of drill point, 0.5mm through)
X65.                             (second hole)
Y55.                             (third)
X15.                             (fourth)
G80                              (cycle off, on its own line, before any other move)
G00 Z25. M09                     (G00 written out, not left to the restored mode)
M05
T05 M06                          (12mm 3 flute end mill)
S4200 M03                        (158m/min)
G00 X-10. Y35.                   (lead in off the end of the plate)
G43 H05 Z25. M08                 (new length offset, coolant back on)
G00 Z2.
G01 Z-5. F250                    (plunge in air, F written again for this tool)
X90. F1200                       (slot straight across, 5mm deep, one pass)
G00 Z25. M09
G49
G91 G28 Z0.                      (home Z)
M30

Controller differences

ControlBehaviour
FanucG80 sits in modal group 09, and any group 01 code cancels a cycle as well, so a lone G00 block ends it. The R, Z, Q and dwell values the cycle was holding go at the same time. The group 01 mode that was live before the cycle becomes active again after G80, which is the reason the retract underneath it is written with an explicit G00 rather than a bare Z word.
HaasCancels the same way, but what happens at the end of a program is a setting rather than a rule. Setting 56, M30 Restore Default G, returns the modal codes to their defaults, G80 among them. With that setting off, a cycle left running is still in group 09 when the next program starts on that machine.
Siemens 840DThe native language has no G80, because a cycle is not made modal by a G code in the first place: MCALL does that. MCALL written on its own, with no cycle name after it, is the cancel. G80 only means anything in ISO dialect mode.
MazakEIA/ISO programs cancel as on Fanuc. A Mazatrol conversational program has nothing to cancel, because the cycle belongs to the unit and ends where the unit ends.
GrblG80 is in the supported list and there is no canned cycle for it to cancel, so it is a plain motion mode cancel. Once G80 is active a block carrying only axis words has no motion mode to use them, and Grbl answers with an error rather than moving, where a Fanuc would move in the mode it restored.

What goes wrong

A drill that bores its way to the next operation was left in a cycle. Every hole in the pattern comes out right, the program reads as though it finished, and the positioning block after the last hole plunges at whatever X and Y it was sent to, usually into a toe clamp or the fixture plate underneath. G80 belongs on its own line the moment the pattern is done.

Next is the move directly under the cancel. G80 hands the control back the group 01 mode that was running before the cycle started, so a bare Z25. there travels in whatever that turns out to be. Where G01 was the last one, 27mm of retract crawls out at the drilling feed of F280, which looks like a hung machine and ends with somebody pressing reset mid-retract.

Third, the feed does not leave with the cycle. G80 clears R, Z, Q and the dwell and leaves F exactly where the drill set it, so the first pass of a 12mm cutter runs at 280mm/min instead of 1200. At 4200rpm that is 0.02mm per tooth, the flutes rub, and the edge builds up before the slot is halfway across. State F on the first cutting block of every tool.

Fourth, a start block with no G80 in it. Stop a drilling program mid pattern, load the next job, and group 09 is still holding the cycle: the first positioning move drills. Keep G80 in the safe start line beside G40 and G49.

Last, posting G80 at a control that reads it differently. Siemens native cancels with MCALL, and on Grbl the axis words under a G80 stop the stream with an error instead of moving.

Updated 11 Oct 2026