Home › M-codes › Siemens 840D 828D › M6
M6 Tool change
Siemens 840D 828D M-code · Mill and lathe
Changes to the tool selected with T. The D number activates the tool offset. On many lathes the turret indexes on T alone without M6, set by machine data.
Format
T M6 or T D M6
Addresses
| Address | What it does |
|---|---|
T | Tool number or tool name, for example T="DRILL10" |
D | Offset number of the tool, D1 if not written on most machines |
How it works
Non modal.
Example program
G0 SUPA Z0 D0 ; Z TO MACHINE ZERO
T="DRILL10" ; SELECT TOOL BY NAME
M6 ; CHANGE TOOL
D1 ; OFFSET ON
T="DRILL10" ; SELECT TOOL BY NAME
M6 ; CHANGE TOOL
D1 ; OFFSET ON
Example is in inch. Check offsets and clearances first.
Watch out for
- Move to a safe position before M6. The tool change sequence is written by the machine builder.
- With tool management, T can be a name in quotes.
Machine builders set many M codes, and they change by model and options. Check the M code list for your machine.
Related codes
M6 on other controls
The same number can mean something different on another control.
| Control | Meaning |
|---|---|
| Fanuc | Tool change |
| Haas NGC | Tool change |
| Doosan (Fanuc) | Atc tool change command |
| DMG Mori MAPPS (Fanuc) | Tool change |
| Mazak (EIA) | Chuck unclamp (releasing workpiece) |
| Okuma OSP | Tool Change |
| Mitsubishi M70 M80 | Tool change |
| Brother Speedio | Tool change |
| Heidenhain TNC (ISO) | Tool change |
| Fagor 8055 8065 | Tool change |
| LinuxCNC Tormach | Tool change |
| Mach3 Mach4 | Tool change |
| Centroid CNC12 Acorn | Tool change |
| Hurco WinMax (NC) | Tool change |
| Fadal | Tool change |
| Swiss (Citizen Star) | Main chuck close (Citizen) |
Every M-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 M6 in the app All Siemens 840D 828D M-codes