CNC G-Code & M-Code Programming 3 — Questions and Answers
Question 1: What G-code is used to set the tool length offset?
- G43 (Correct answer)
- G41
- G49
- G44
Correct answer: G43
G43 applies a positive tool length offset from the H-word register to compensate for tool length differences.
Question 2: In a CNC program block 'G02 X2.0 Y0.0 I1.0 J0.0', what do I and J represent?
- Arc center offsets from the start point (Correct answer)
- Arc radius in X and Y
- End point coordinates
- Feed rate components
Correct answer: Arc center offsets from the start point
I and J define the distance and direction from the arc start point to the arc center in the X and Y axes respectively.
Question 3: Which M-code activates flood coolant?
- M08 (Correct answer)
- M07
- M09
- M01
Correct answer: M08
M08 turns on flood coolant, which delivers a high volume of liquid coolant to the cutting zone.
Question 4: What is a 'canned cycle' in CNC programming?
- A pre-programmed multi-step operation called with a single G-code (Correct answer)
- A repeated loop of the entire program
- A subroutine for circular pockets
- A fixed spindle speed sequence
Correct answer: A pre-programmed multi-step operation called with a single G-code
Canned cycles (G73–G89) are built-in multi-step routines like drilling, tapping, and boring activated by a single G-code block.
Question 5: What does a negative I or J value indicate in arc programming?
- The arc center is in the negative direction from the start point (Correct answer)
- The arc moves clockwise
- The arc radius is subtracted
- The feed rate is reduced
Correct answer: The arc center is in the negative direction from the start point
Negative I or J values mean the arc center is located in the negative X or Y direction relative to the arc's starting point.
Question 6: Which G-code cancels tool length compensation?
- G49 (Correct answer)
- G43
- G44
- G40
Correct answer: G49
G49 cancels any active tool length offset, returning the tool to its programmed position without compensation.
Question 7: In CNC turning, what does 'G71' typically command?
- Rough turning cycle (Correct answer)
- Fine boring cycle
- Thread cutting cycle
- Grooving cycle
Correct answer: Rough turning cycle
G71 is a stock removal (rough turning) canned cycle that removes material in multiple passes along a defined contour.
What G-code is used to set the tool length offset?