We use technical and security cookies and, only if you accept, analytics with no cross-site tracking. More in the Cookie policy and Privacy policy.
We use first-party cookies and technical storage to make the site work, Google reCAPTCHA security technology and, only if you accept, Vercel analytics (no cookies, no cross-site tracking). You can accept or reject analytics; both options are equivalent and you can change your choice at any time. More info: Cookie policy, Privacy policy, Legal notice and Terms and conditions.
G96 switches constant surface speed on: you program the cutting speed in meters per minute and the control works out at every instant the rpm needed for the diameter the tool tip is standing at, so the spindle speeds up as it closes on the center. G97 does exactly the opposite: it fixes the rpm and holds them whatever happens. With G96 you always have to set a speed limit, which on Fanuc and Haas lathes is programmed with G50 S and goes before the G96.
For reference only: syntax changes with the control, the post-processor and the machine parameters. Check the official manual and run a simulation before cutting. Legal notice.
Family
Spindle
Machine
Turning, Mill-turn
Risk
High
Example
G96 S180 M03 / G97 S1200
Syntax by control
Fanuc lathe (A code system)
G50S2200; G96 S200 M03
In the A code system, G50 with an S limits the maximum spindle speed. That same G50 with no S is the coordinate system setting, so the S is what tells the two functions apart. In the B and C systems the speed limit is programmed with G92 S.
Haas (turning)
G50S2200; G96 S200 M03
Same logic as Fanuc: G50 S sets the speed ceiling and G96 the cutting speed. Haas also keeps its own machine maximum and the chuck maximum, which override whatever you write.
Siemens 840D / 828D (turning)
LIMS=2200G96S200M3
On Siemens the speed limit is written with LIMS and the cutting speed with G96 S. G97 puts the spindle back on direct rpm. There is also G973, which keeps constant surface speed without tying it to feed per revolution.
Heidenhain TNC with turning option
FUNCTIONTURNDATASPINVCONST:ONVC:200VMAX:2200
The TNCs use neither G96 nor G97: in turning mode, constant surface speed is switched on with FUNCTION TURNDATA SPIN VCONST:ON and limited with VMAX. It is a machine option: if the TNC has no turning package, the instruction does not exist.
Fanuc / Haas (back to direct rpm)
G97S1200M03
G97 cancels G96 on any of the controls above. It is what you have to write before drilling or tapping on center, and also before parting off near the center unless you want the spindle to run up to its ceiling.
Address letters used with it
Letter
What it sets
Unit
S (with G96)
Cutting speed you want to hold at the edge. It is not rpm: G96 S200 is 200 meters per minute, which at 50 mm diameter works out at 1273 rpm and at 20 mm at 3183.
m/min in metric (sfm under G20 in inches)
S (with G97)
Fixed spindle rpm, with no relation to the diameter. It is the same as the S on a milling machine.
rpm
S (with G50 or G92)
Maximum spindle speed ceiling while G96 is active. It is the instruction that stops the spindle running away as it reaches the center of the part.
rpm
X (current position)
It is not written with the G96, but it is what is in charge: the control reads the diameter the tip is standing at, offsets included, and works the rpm out from there.
mm of diameter (or of radius, depending on the control convention)
M03 / M04
Direction of rotation. G96 and G97 only say how fast, not which way, and they need the matching M to start.
no units
Worked example
Facing and turning a 60 mm steel bar held in the chuck. With a cutting speed of 200 m/min, at 60 mm diameter the control turns at 1061 rpm; reaching 10 mm it would ask for 6366 and at 2 mm, nearly 32,000. That is why the limit block goes before the G96 and not after. At the end a drill goes in on center, where constant surface speed makes no sense at all.
O0096(REFRENTADO CON G96 Y LIMITE DE RPM)
( Program header. )
G21G18G40
( Millimeters, XZ plane and no tool nose radius compensation active. )
G50S2200
( Speed ceiling. You pick it from the chuck limit, the out of balance of the part and what the jaws will hold, not from what the motor can take. This block moves nothing: it only sets the roof. )
T0101(PLAQUITA DE REFRENTAR)
( Tool 1 with its offset 1. )
G96S200M03
( Constant surface speed of 200 m/min, clockwise. The rpm are decided by the control from the diameter the tip is standing at. )
G99G00X62.Z0.
( Feed per revolution (G95 in the B and C code systems) and rapid approach to the face. At 62 mm diameter the spindle is turning at about 1027 rpm. )
G01X-1.6F0.2
( Facing 0.8 mm past the center so no pip is left. As the diameter drops, the control raises the rpm; at 10 mm it would want 6366 rpm and it stays at the 2200 of the G50. )
G00Z2.
( Pulls the insert off the face before coming out in X. )
G00X60.
( Positions for the turning pass. )
G01Z-45.F0.3
( Turning. Here the diameter hardly changes, so the rpm hold around 1061 and the cutting speed really is constant. )
G00X200.Z100.
( Retract to the turret index position, with the spindle slowing down as the diameter grows. )
T0303(BROCA DE Ø14)
( Tool 3 with its offset. )
G97S1000M03
( Direct rpm. It is compulsory: the drill works at X0, and with G96 the control would ask for infinite rpm and sit pinned at the limit. )
G96 is for everything that travels across different diameters: facing, cutting tapers, radii and profiles, turning steps of very different sizes or parting off on the outside. There, holding the cutting speed is what gives an even finish and predictable insert life. G97 is for everything that works on the axis or close to it: drilling, reaming, tapping, the last few millimeters of a part off. Also for off center parts, long bars with no steady rest or weak workholding, where the last thing you want is the control deciding to raise the rpm on its own.
Why the speed limit is not optional
The formula the control uses is rpm equals cutting speed times a thousand divided by pi times the diameter. As the diameter tends to zero, the rpm tend to infinity: facing to the center, the control asks for everything the spindle can give. The danger is not the motor, it is the centrifugal force on the chuck and the jaws, which grows with the square of the rpm and can loosen the grip on the part. That is why G50 S (or G92 S, or LIMS) is written before the G96 and chosen for the chuck and the workholding, not for the spindle.
What diameter the control reads and what can falsify it
The control does not know what diameter the part has: it knows what X the tip is at, with the active offset added. If the offset is wrong, the real cutting speed is not the programmed one, even though the screen shows the right number. The same goes for the diameter or radius convention: in radius programming, the X of a 50 mm diameter is 25, and if the control expects diameter the cutting speed comes out double. And near the center there is another physical effect: the spindle has limited acceleration, so in a fast facing pass the rpm always lag behind what the arithmetic asks for.
Mistakes that cost you a part (or a tool)
Facing or parting off to the center without having set the limit with G50 S: the spindle runs up to its maximum with the part in the chuck, which is the commonest way to have a part thrown out.
Writing the G50 S after the G96 or with the spindle already running: the limit has to be active before the control starts working rpm out.
Drilling, reaming or tapping on center with G96 active: at X0 the control asks for infinite rpm, plants itself at the ceiling and the tool works at a speed that has nothing to do with the plan.
Reading the S of a G96 as rpm: G96 S180 is 180 meters per minute, not 180 rpm. On a 40 mm bar that is nearly 1500 rpm.
Mixing up the G50 of the speed limit with the G50 of lathe coordinate setting or the G50 of milling machine scaling: different functions sharing a number, and in the B and C code systems the limit is G92 S.
Programming in radius with the control set up in diameter (or the other way around): the rpm it works out come out double or half of the plan across the whole part.
Leaving G96 on for the move to the turret index position and coming straight back to a small diameter: the spindle spends the move accelerating and braking, cycle time is lost and the drive takes a beating.
Frequently Asked Questions (FAQ)
Is the S of G96 rpm?
No. Under G96 the S is the cutting speed in meters per minute (or in feet per minute if the control is in inches under G20). The rpm are worked out by the control moment by moment. Under G97, on the other hand, the S really is direct rpm.
How does the control work the rpm out under G96?
With the usual formula: rpm equals cutting speed times 1000 divided by pi times the diameter. With G96 S200 at a diameter of 60 mm that is 1061 rpm; at 20 mm it is 3183; at 5 mm it is 12,732, and that is where the G50 S limit comes in.
Why does the spindle speed up when I face?
Because the tool is heading for the center and the diameter is dropping: to hold the same meters per minute at the edge, the control has to raise the rpm. That is G96 behaving correctly, and the only reason for it to be frightening is not having set the maximum limit.
Do I use G50 or G92 to limit the rpm?
It depends on the code system of the lathe. In the Fanuc A system and on Haas lathes it is G50 S. In the Fanuc B and C systems it is G92 S. On Siemens it is LIMS and on TNCs with turning it is the VMAX parameter of FUNCTION TURNDATA SPIN. Check it in the manual before the first part.
Does G96 exist on a milling machine?
On an ordinary mill, no: the S is always rpm and you work the cutting speed out yourself when you pick them. On mill-turn centers it does appear, but only during turning operations, not when live tooling is cutting.