Bird
Raised Fist0
CNC Programmingscripting~10 mins

Coolant control (M08, M09) in CNC Programming - Step-by-Step Execution

Choose your learning style10 modes available
Concept Flow - Coolant control (M08, M09)
Start Program
↓
Check for M08
Yes / No↓
Turn ON Coolant
↓
Coolant ON
↓
Turn OFF Coolant
↓
Continue Program
↓
Coolant OFF
↓
Continue Program
↓
End Program
The program checks for M08 to turn coolant ON and M09 to turn coolant OFF, then continues execution.
Execution Sample
CNC Programming
N10 M08 ; Turn coolant ON
N20 G01 X10 Y10 F100
N30 M09 ; Turn coolant OFF
N40 G00 X0 Y0
This CNC code turns coolant ON at line 10, moves the tool, then turns coolant OFF at line 30.
Execution Table
StepLineCommandCoolant StateAction Taken
1N10M08OFF -> ONCoolant turned ON
2N20G01 X10 Y10 F100ONTool moves with coolant ON
3N30M09ON -> OFFCoolant turned OFF
4N40G00 X0 Y0OFFTool moves with coolant OFF
5---Program ends
💡 Program ends after last line; coolant state remains OFF.
Variable Tracker
VariableStartAfter Step 1After Step 2After Step 3After Step 4Final
Coolant StateOFFONONOFFOFFOFF
Key Moments - 2 Insights
Why does the coolant state change only at M08 and M09 lines?
Because M08 turns coolant ON and M09 turns it OFF, as shown in execution_table steps 1 and 3. Other commands do not affect coolant.
What happens if M09 is missing after M08?
Coolant stays ON after M08, so it remains ON until turned OFF or program ends, as seen in variable_tracker final state if step 3 was skipped.
Visual Quiz - 3 Questions
Test your understanding
Look at the execution table, what is the coolant state after executing line N20?
AON
BOFF
CTurning ON
DTurning OFF
💡 Hint
Check execution_table row 2 under 'Coolant State' column.
At which step does the coolant turn OFF?
AStep 1
BStep 2
CStep 3
DStep 4
💡 Hint
Look at execution_table row 3 for coolant state change.
If M08 was not used, what would be the coolant state at step 2?
AON
BOFF
CTurning ON
DUnknown
💡 Hint
Refer to variable_tracker and execution_table to see coolant state changes only happen at M08 and M09.
Concept Snapshot
M08 turns coolant ON.
M09 turns coolant OFF.
Coolant state persists until changed.
Use M08 before cutting moves.
Use M09 to stop coolant after cutting.
Commands between do not affect coolant.
Full Transcript
This CNC program uses M08 to turn coolant ON and M09 to turn it OFF. The flow checks for these commands and changes coolant state accordingly. The execution table shows each line's command and coolant state changes. The variable tracker follows coolant state through the program. Key moments clarify that only M08 and M09 affect coolant. The visual quiz tests understanding of coolant state at different steps. Remember, coolant stays ON after M08 until M09 turns it OFF.

Practice

(1/5)
1. What does the CNC command M08 do in a machining program?
easy
A. Starts the spindle rotation
B. Turns the coolant off to stop coolant flow
C. Turns the coolant on to cool the tool and workpiece
D. Stops the spindle rotation

Solution

  1. Step 1: Understand the function of M08

    The M08 command is used to turn coolant on in CNC machining to cool tools and workpieces.
  2. Step 2: Compare with other commands

    M09 is used to turn coolant off, spindle commands are different (M03, M05).
  3. Final Answer:

    Turns the coolant on to cool the tool and workpiece -> Option C
  4. Quick Check:

    M08 = Coolant ON [OK]
Hint: M08 means coolant ON, M09 means coolant OFF [OK]
Common Mistakes:
  • Confusing M08 with M09
  • Thinking M08 controls spindle
  • Mixing coolant commands with feed rate commands
2. Which of the following is the correct syntax to turn coolant off in a CNC program?
easy
A. M10
B. M08
C. M07
D. M09

Solution

  1. Step 1: Identify the command for coolant off

    M09 is the standard CNC command to turn coolant off and stop coolant flow.
  2. Step 2: Verify other options

    M08 turns coolant on, M07 and M10 are unrelated or non-standard for coolant control.
  3. Final Answer:

    M09 -> Option D
  4. Quick Check:

    M09 = Coolant OFF [OK]
Hint: M09 always stops coolant flow in CNC programs [OK]
Common Mistakes:
  • Using M08 instead of M09 to stop coolant
  • Confusing M07 with coolant off
  • Assuming M10 controls coolant
3. Given the following CNC program snippet, what is the coolant state after line 3?
N10 M08
N20 G01 X50 Y50 F100
N30 M09
medium
A. Coolant is OFF
B. Coolant is ON
C. Coolant state is unchanged
D. Coolant cycles ON and OFF rapidly

Solution

  1. Step 1: Analyze line 1 (N10 M08)

    M08 turns coolant ON at line 10.
  2. Step 2: Analyze line 3 (N30 M09)

    M09 turns coolant OFF at line 30, which is after line 20.
  3. Final Answer:

    Coolant is OFF -> Option A
  4. Quick Check:

    Last coolant command is M09 = OFF [OK]
Hint: Last coolant command controls coolant state [OK]
Common Mistakes:
  • Ignoring the M09 command at line 30
  • Assuming coolant stays ON after M09
  • Confusing line numbers with command effect
4. Identify the error in this CNC program snippet related to coolant control:
N10 M09
N20 G01 X100 Y100 F200
N30 M08
medium
A. Coolant is turned on after machining moves start
B. Coolant is turned off before machining starts
C. M09 and M08 commands are reversed
D. No error, coolant control is correct

Solution

  1. Step 1: Check coolant commands order

    M09 at N10 turns coolant off before machining moves.
  2. Step 2: Check machining and coolant timing

    Machining move at N20 happens with coolant off, then coolant turns on at N30, which is after machining started.
  3. Final Answer:

    Coolant is turned on after machining moves start -> Option A
  4. Quick Check:

    Coolant ON should be before machining moves [OK]
Hint: Turn coolant ON before machining moves start [OK]
Common Mistakes:
  • Turning coolant on after machining moves
  • Assuming coolant off at start is always correct
  • Ignoring command sequence importance
5. You want to write a CNC program that starts coolant before cutting, stops coolant after cutting, and ensures coolant is off at program end. Which sequence of commands is correct?
hard
A. M09 before cutting moves, M09 after cutting moves, M08 at program end
B. M08 before cutting moves, M09 after cutting moves, M09 at program end
C. M08 before cutting moves, M08 after cutting moves, M09 at program end
D. M09 before cutting moves, M08 after cutting moves, M08 at program end

Solution

  1. Step 1: Turn coolant ON before cutting

    M08 must be used before cutting moves to cool tools and workpiece.
  2. Step 2: Turn coolant OFF after cutting and at program end

    M09 stops coolant flow after cutting and ensures coolant is off at program end.
  3. Final Answer:

    M08 before cutting moves, M09 after cutting moves, M09 at program end -> Option B
  4. Quick Check:

    Coolant ON before cut, OFF after cut and end [OK]
Hint: Always end program with coolant OFF (M09) [OK]
Common Mistakes:
  • Starting with coolant OFF (M09) before cutting
  • Leaving coolant ON at program end
  • Using M08 to turn coolant off
Recommended

Ready to prove it?

Pass the test and this pattern moves unknown strong while earning +1 Grip toward your certificate.

10 questions~5 mineasy hard