Back to GSM Code List

M07: the second coolant output of the machine

M07 switches on the machine's secondary coolant output, which in most cases is mist or air with a touch of lubricant, and it is shut off with M09 just like flood. The important part is in most cases: M07 is one of those functions every builder maps into the PLC however it likes, so on one machine it puts out mist, on another compressed air, on another a chip wash and on another nothing at all.

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
Machine
Machine
Milling, Turning, Mill-turn
Risk
Low
Example
M07

Syntax by control

Fanuc

M07

The code takes no arguments. What it does depends entirely on the machine PLC: it can be mapped to mist, to air, to an auxiliary output or to nothing. In the ISO standard the pair is M07 coolant number 2 and M08 coolant number 1.

Haas

M07

On Haas it usually matches an installed option, such as mist or the chip wash. If the machine does not have that option, the code does nothing or alarms. Through-spindle coolant is another matter and goes with M88 and M89.

Siemens 840D / 828D

M7

M7 and M8 are reserved for the two coolant outputs, but what they really mean is decided by the machine builder in the PLC. They are written with no leading zero.

Heidenhain TNC (Klartext)

M7

Same as on Siemens: M7 corresponds to the second coolant circuit and its actual function is defined by the builder. On many TNCs you can also tie the coolant to the tool call from the table.

Address letters used with it

LetterWhat it setsUnit
No address lettersM07 goes alone in its block or alongside a move. It takes no arguments: pressure, flow and nozzle are set on the machine, not in the program.no units
M08The other output, normally flood. On some machines they run together and on others they exclude each other: switching one on turns the other off. It depends on the PLC.no units
M09Shuts the coolant off. It is the only off code: there is no specific shutdown for M07, so M09 turns both outputs off at once.no units
G04 P (associated dwell)It is not part of M07, but it is used with it: a short dwell after opening the mist gives the line time to charge so the nozzle is already delivering before the tool goes in.ms on Fanuc, seconds with decimals on Haas

Worked example

Slotting an aluminum plate with a three flute cutter and mist lubrication. The mist takes a couple of seconds to reach the nozzle, so the program opens it before coming down and waits. At the end, the M09 shuts off every coolant output on the machine, mist included, because there is no code of its own to close just the M07.

O0007 (RANURA EN ALUMINIO CON NIEBLA)
( Program header. )
G21 G17 G40 G49 G80
( Millimeters, XY plane and a clean state. )
G91 G28 Z0.
( Z to the reference point in incremental before the change. )
T2 M06 (FRESA D8 DE 3 FILOS)
( Three flute cutter for aluminum. )
G90 G54 G00 X10. Y25. S9000 M03
( Absolute, work offset, positioning over the start of the slot and spindle on. )
G43 H02 Z50.
( T2 length offset. )
M07
( Opens the mist output. The first time, check it dry with the door closed: on some machines this same code puts out air only and on others it does nothing. )
G04 P2000
( A two second dwell so the line charges. On Fanuc the P is in milliseconds, so P2000 is 2 s; on Haas you would write P2. because it counts in seconds. )
G00 Z2.
( Approach, with the nozzle already delivering. )
G01 Z-3. F400
( Feeds down to the depth of the slot. )
G01 X110. F1800
( Slot along the plate. In aluminum, mist is mostly there to keep the chip from welding to the edge. )
G00 Z50.
( Retract in Z. )
M09
( Shuts the coolant off. M09 turns off every output on the machine: there is no separate code to close only the mist. )
G91 G28 Z0. M05
( Z to the reference point and spindle stop. )
G90 M30
( Back to absolute and end. )
Open the simulator to check the example

Practical keys to using M07 in the workshop

What M07 actually is

In the standard, M07 is coolant number 2 and M08 number 1. What sits behind that number 2 is decided by the machine builder when the PLC is written, and that is why the honest answer to what M07 does is it depends. The commonest mappings are mist or minimum quantity lubrication, compressed air through the nozzle, a second pump at another pressure or an auxiliary wash circuit. There are machines where M07 and M08 run together and machines where switching one on turns the other off. The only thing common to all of them is that M09 turns them off.

When you want mist and when you want flood

Mist shines where the problem is sticking and not heat: aluminum, brass, saws and slitting cutters, tapping small parts, finish passes where flood would push the chip against the wall. Also on machines without good sealing or on jobs where you do not want to soak the part. Flood is still better when you have to get chips out of a deep hole, genuinely cool a roughing pass in steel or hold a stable temperature for a tight tolerance. And there is a third criterion, health: mist is breathed in and needs an enclosed machine and extraction.

How to find out what M07 does on your machine

Three checks that take a minute and save a wasted program. The first, the M code list in the builder's manual, which is the only reliable source. The second, running it in manual or MDI with the door closed and watching what comes out where. The third, the PLC output diagnostic screen, if the machine has one, where you see the signal switching on. And one rule: do not copy a block with M07 from one machine in the shop to another without repeating that check, even if they are from the same builder and look identical.

Mistakes that cost you a part (or a tool)

  • Assuming M07 exists on the machine: if the option is not installed, the code can amount to nothing and the whole program runs dry with no warning at all.
  • Expecting flood and getting mist in a deep hole: with no flow the chips do not clear, the drill grabs on the second peck and breaks off down the hole.
  • Looking for a specific code to close the mist: there is not one. The off command is M09 and it shuts every coolant output at once.
  • Opening M07 in the same block the tool enters the material: the line takes time to charge and the first few millimeters are cut dry. A short dwell before coming down fixes it.
  • Working with mist and the door open or with no extraction: it is an oil aerosol that gets breathed in and that also leaves the floor slippery around the machine.
  • Using oil mist for roughing steel with glowing chips: besides cooling poorly, the aerosol and the sparks inside an enclosure are a combination that has started fires.
  • Copying programs between machines in the shop without reviewing the M07: the same code can be mist on one, air on another and a useless auxiliary output on the third.

Frequently Asked Questions (FAQ)

What is the difference between M07 and M08?

M08 is the main output, which on almost every machine is the flood of cutting fluid. M07 is the secondary one, most often mist or air with lubricant. The real difference is defined by the builder in the PLC, so the machine next door may not match. Both are turned off with M09.

How do I check what M07 does on my machine?

Look at the M code list in the builder's manual, not the generic Fanuc or Haas one, and then run it in MDI with the door closed to see what comes out. If the machine has an output diagnostic screen, the signal shows up there. What does not work is assuming it from what another machine does.

Can I have M07 and M08 on at the same time?

On some machines yes and on others no: there are PLCs where the two outputs coexist and others where switching one on turns the other off automatically. It is a builder decision. Try it dry before counting on it in a production program.

Is M07 the through-spindle coolant?

Normally not. Coolant through the spindle usually has its own codes: on Haas they are M88 to open and M89 to close, and other builders use different numbers. Mixing the two up leaves a long drill working without the internal flow it needs.

Can you program the mist pressure or flow?

Not with M07: the code is a switch with no arguments. Flow, pressure and nozzle aim are set on the machine's own equipment. Some machines with advanced coolant systems have their own M codes to change pressure level, and that is a builder matter.

Related codes

Other codes in Machine

See the full list of G and M codes

Related tools