Home › G-codes › LinuxCNC Tormach › G7
G7 Lathe diameter mode
LinuxCNC Tormach G-code · Lathe
Makes X words read as diameter on a lathe. X1 puts the tool at a 1.0 inch diameter, half an inch from center.
Format
G7
Addresses
| Address | What it does |
|---|---|
none | No words |
How it works
Modal. Stays on until G8.
Example program
G20 G18 G7 G40 G80 G90 G94 (INCH, XZ PLANE, DIAMETER MODE)
T1 M6 G43 (TURNING TOOL)
G96 D2500 S500 M3 (CSS 500 SFM, 2500 RPM MAX)
G0 X1.05 Z0.1 (1.05 DIAMETER)
…
T1 M6 G43 (TURNING TOOL)
G96 D2500 S500 M3 (CSS 500 SFM, 2500 RPM MAX)
G0 X1.05 Z0.1 (1.05 DIAMETER)
…
The full 5-line example is in the app. Example is in inch. Check offsets and clearances first.
Watch out for
- Stock LinuxCNC powers up in G8 radius mode unless the INI startup codes add G7. Put G7 or G8 at the top of every lathe program.
- Tormach PathPilot lathe works in diameter mode. Mixing up modes doubles or halves every X move.
Related codes
G7 on other controls
The same number can mean something different on another control.
| Control | Meaning |
|---|---|
| Heidenhain TNC (ISO) | Paraxial positioning block |
| Fagor 8055 8065 | Square corner |
Every G-code for LinuxCNC Tormach 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 G7 in the app All LinuxCNC Tormach G-codes