G98 Canned cycle return to initial level / Feed per minute
Fanuc G-code · Mill, Lathe
On mills: Canned cycle return to initial level
After each hole in a canned cycle the tool returns to the initial level, the Z height it was at before the cycle started. Use it to clear clamps between holes.
Format
G98
How it works
Modal, group 10. Usually the power on default.
Example program
G43 H01 Z1. (INITIAL LEVEL Z1.)
G98 G81 X1. Y1. Z-.5 R.1 F8. (RETURN TO Z1. AFTER EACH HOLE)
X4. (OVER THE CLAMP SAFELY)
G80 (CANCEL)
G98 G81 X1. Y1. Z-.5 R.1 F8. (RETURN TO Z1. AFTER EACH HOLE)
X4. (OVER THE CLAMP SAFELY)
G80 (CANCEL)
Example is in inch. Check offsets and clearances first.
Watch out for
- The initial level is the Z position when the cycle was first called, so set a safe Z before the cycle.
- G87 back boring allows only G98.
On lathes: Feed per minute
In G code system A, G98 makes F inches per minute. Used for live tool milling and drilling. It is not a canned cycle return code here.
Format
G98
How it works
Modal, group 05. Cancel with G99.
Example program
G98 (FEED PER MINUTE)
G01 Z-.1 F10. (10 IPM)
G99 (BACK TO FEED PER REV)
G01 Z-.1 F10. (10 IPM)
G99 (BACK TO FEED PER REV)
Example is in inch. Check offsets and clearances first.
Watch out for
- Switch back to G99 before turning, or an F of .008 will barely move.
- Write F with a decimal point, for example F10.
Related codes
G98 on other controls
The same number can mean something different on another control.
| Control | Meaning |
|---|---|
| Haas NGC | Canned cycle initial point return |
| Mazak (EIA) | Canned cycle return to initial point |
| Mitsubishi M70 M80 | Canned cycle return to start level |
| Brother Speedio | Canned cycle return to initial point |
| Heidenhain TNC (ISO) | Set label |
| Fagor 8055 8065 | Return to initial plane |
| LinuxCNC Tormach | Cycle retract to start height |
| Mach3 Mach4 | Cycle return to initial point |
| Centroid CNC12 Acorn | Canned cycle return to start height |
| Hurco WinMax (NC) | Cycle return to initial point |
| Fadal | Fixed cycle return to start plane |
| Swiss (Citizen Star) | Feed per minute |
Every G-code for Fanuc in your pocket. The app has the full example programs, search by number or shop word, a line decoder and calculators for tapping, threading and drilling.
Open G98 in the app All Fanuc G-codes