M29

Machining center, LatheReference: one source only

Rigid tapping (switches the spindle to position control) *machine-dependent*

Format and notes

M29 S_ ; G84 X_ Y_ Z_ R_ F_

Most M codes are assigned by the machine builder (the Siemens ISO dialect manual leaves M00–M89 to the machine tool maker). The same number can mean different things on different machines, so always check your machine’s manual.

Differences between controls and machines

The same code can be written or assigned differently depending on the CNC control and the machine builder. Always check your machine’s manual.

SourceMachineItemDetail
HaasMachining centerMeaningSet output relay with M-finM29 on Haas mills is not rigid tapping. Haas G84 works without M29
HaasLatheAvailabilityNo M29 in the lathe M-code list

Frequently asked questions about M29

What is M29 (Rigid tapping (switches the spindle to position control) *machine-dependent*) used for and how is it formatted in a CNC program?
M29 commands "Rigid tapping (switches the spindle to position control) *machine-dependent*" on Machining center, Lathe. The standard program format is "M29 S_ ; G84 X_ Y_ Z_ R_ F_". On FANUC-type controls, it is commonly commanded before G84/G74 to enter rigid (synchronized) tapping
Is M29 a modal code or a one-shot (non-modal) code?
Whether M29 acts modally or as a single-block command depends on the CNC control and the machine builder’s PLC ladder implementation. Check your machine’s active modal status screen and programming manual before running in auto mode.
Does M29 work differently on machining centers (mills) versus CNC lathes?
M29 is primarily used on Machining center, Lathe. Depending on the machine type and the lathe G-code system (System A, B, or C), this code may be unavailable or assigned to a different function, so verify against your machine tool manual.
Are there differences in M29 across FANUC, Mitsubishi, Okuma, Haas, and Siemens controls?
Yes. Control builders such as FANUC, Mitsubishi Electric (M80/M800), Okuma (OSP), Haas, Mazak, Siemens (SINUMERIK ISO dialect), and Heidenhain can differ in argument letters, decimal-point rules, and optional parameters for M29. Review the control comparison table above and verify the exact syntax in your machine’s programming manual before proving out the program.

Sources

Only one source could be checked for the meaning of this code, so treat it as a reference. Explanations are written in our own words.

  1. Siemens AG — SINUMERIK 802D sl/840D/840D sl/840Di/840Di sl/810D Programming Manual ISO Milling, 04.2007 Edition (6FC5398-7BP10-0BA0) cache.industry.siemens.com
  2. Haas Automation, Inc. — Mill Operator's Manual – 18 Mill M-Codes (online version) haascnc.com
  3. Haas Automation, Inc. — Lathe Operator's Manual – 17 Lathe M-Codes (online version) haascnc.com