G-code reference

G38.3 G-Code: Straight Probe Toward Workpiece (No Error)

Straight Probe Toward Workpiece (No Error) — Like G38.2 but no error is raised if the probe does not trigger. Macros can then check whether contact happened. G38.4 and G38.5 probe away from the workpiece…

By cnccode · Updated
PropertyValue
CodeG38.3
FunctionStraight Probe Toward Workpiece (No Error)
Modal group01
TypeOne-shot (non-modal) — active only in its own block
Used onMilling machines
SyntaxG38.3 X_ Y_ Z_ F_

What does G38.3 do?

Like G38.2 but no error is raised if the probe does not trigger. Macros can then check whether contact happened. G38.4 and G38.5 probe away from the workpiece (until the contact opens).

G38.3 is a one-shot code: it only acts in the block where it is written, and the previously active modal codes take over again afterwards.

Syntax and parameters

Format
G38.3 X_ Y_ Z_ F_

G38.3 example program

Example
G91 G38.3 X20 F100
G90

▶ Open this example in the G-code viewer

Controller compatibility

G38.3 follows the ISO/Fanuc dialect used by Fanuc, Haas, Brother, Doosan, Hurco (ISO mode), Mazak (EIA/ISO mode), Okuma (G-code mode) and Siemens in ISO dialect mode. Parameters, option packages and builder-specific behaviour can differ, so confirm the details in your machine's programming manual before running a new program.

Frequently asked questions

Is G38.3 modal?
No. G38.3 is a one-shot (group 00) code and only acts in the block where it appears.
What does G38.3 mean in CNC?
G38.3 means Straight Probe Toward Workpiece (No Error). Like G38.2 but no error is raised if the probe does not trigger. Macros can then check whether contact happened. G38.4 and G38.5 probe away from the workpiece (until the contact opens).
What is the difference between G38.3 and G38.2?
G38.3 is Straight Probe Toward Workpiece (No Error), while G38.2 is Straight Probe Toward Workpiece (Stop on Contact, Error if Not). See the G38.2 page for its syntax and examples.
Can I use G38.3 on a lathe?
Usually not with the same meaning: G38.3 is documented here for milling machines. Check your control manual for the equivalent.