Home › G-codes › Siemens 840D 828D › G4
G4 Dwell for time or spindle revolutions
Siemens 840D 828D G-code · Mill and lathe
Pauses axis motion for a set time in seconds (F) or a set number of spindle revolutions (S). Used at the bottom of a hole or groove to clean up the surface.
Format
G4 F or G4 S
Addresses
| Address | What it does |
|---|---|
F | Dwell time in seconds |
S | Dwell in revolutions of the master spindle |
How it works
Non modal. Must be in its own block.
Example program
G1 X30 F0.05 ; PLUNGE TO GROOVE BOTTOM
G4 S2 ; DWELL 2 SPINDLE REVOLUTIONS
G0 X42 ; RETRACT
G4 F0.5 ; DWELL HALF A SECOND
G4 S2 ; DWELL 2 SPINDLE REVOLUTIONS
G0 X42 ; RETRACT
G4 F0.5 ; DWELL HALF A SECOND
Example is in inch. Check offsets and clearances first.
Watch out for
- F and S in the G4 block only set the dwell. The stored feed and spindle speed are not changed.
- Program G4 in a block of its own.
Related codes
G4 on other controls
The same number can mean something different on another control.
| Control | Meaning |
|---|---|
| Fanuc | Dwell |
| Haas NGC | Dwell |
| Mazak (EIA) | Dwell |
| Okuma OSP | Dwell |
| Mitsubishi M70 M80 | Dwell |
| Brother Speedio | Dwell |
| Heidenhain TNC (ISO) | Dwell time |
| Fagor 8055 8065 | Dwell or stop block preparation |
| LinuxCNC Tormach | Dwell |
| Mach3 Mach4 | Dwell |
| Centroid CNC12 Acorn | Dwell |
| Hurco WinMax (NC) | Dwell |
| Fadal | Dwell |
| Swiss (Citizen Star) | Dwell |
Every G-code for Siemens 840D 828D 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 G4 in the app All Siemens 840D 828D G-codes