CNC Machinist Calculator Ultra

Home › M-codes › Siemens 840D 828D › M17

M17 End of subprogram

Siemens 840D 828D M-code · Mill and lathe

Ends a subprogram and returns to the calling program. RET does the same.

Format

M17

How it works

Non modal.

Example program

; SUBPROGRAM L10
G91 G1 X10 F300 ; STEP
G90
M17 ; RETURN TO MAIN PROGRAM

Example is in inch. Check offsets and clearances first.

Watch out for

Machine builders set many M codes, and they change by model and options. Check the M code list for your machine.

Related codes

L · M30

M17 on other controls

The same number can mean something different on another control.

ControlMeaning
Haas NGCPallet unclamp and open APC door
Doosan (Fanuc)Machine lock act
Mazak (EIA)Spindle orientation 120° (for AJC)
Okuma OSPCEJ MATIC : Request of Data transfer
Centroid CNC12 AcornPrepare for tool change, macro
Hurco WinMax (NC)Automatic buffering off
FadalEnd of subroutine, Format 1

Every M-code for Siemens 840D 828D 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 M17 in the app All Siemens 840D 828D M-codes

App Store Google Play