Home › G-codes › Haas NGC › G103
G103 Limit block lookahead / Limit block look ahead
Haas NGC G-code · Mill, Lathe
On mills: Limit block lookahead
Limits how many blocks the control reads ahead. Used to debug macros or to make probe and macro logic run in order.
Format
G103 [P]
Addresses
| Address | What it does |
|---|---|
P | Number of blocks to look ahead, 0 to 15. P0 or no P removes the limit |
How it works
Modal, group 00.
Example program
G103 P1 (LOOK AHEAD ONLY ONE BLOCK)
#100 = #5021 (READ MACHINE X POSITION)
G103 (REMOVE THE LIMIT)
#100 = #5021 (READ MACHINE X POSITION)
G103 (REMOVE THE LIMIT)
Example is in inch. Check offsets and clearances first.
Watch out for
- Small values can cause pauses between moves on contours. Remove the limit when done.
On lathes: Limit block look ahead
Limits how many blocks the control reads ahead, 0 to 15. G103 P1 is used to debug macros and to time outputs with motion.
Format
G103 [P]
Addresses
| Address | What it does |
|---|---|
P | Number of blocks to look ahead. P0 or no P removes the limit |
How it works
Group 00. Stays until another G103.
Example program
G103 P1 (LOOK AHEAD 1 BLOCK)
#12012 = 1 (OUTPUT ON)
G04 P1. (WAIT 1 SECOND)
#12012 = 0 (OUTPUT OFF)
…
#12012 = 1 (OUTPUT ON)
G04 P1. (WAIT 1 SECOND)
#12012 = 0 (OUTPUT OFF)
…
The full 5-line example is in the app. Example is in inch. Check offsets and clearances first.
Watch out for
- Add empty lines after a motion block when macro lines follow G103 P1.
- Limited look ahead slows contour moves. Remove the limit when done.
Related codes
Every G-code for Haas NGC 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 G103 in the app All Haas NGC G-codes