G65 Macro Subprogram Call Option (Group 00)

Classic Control - Lathe Operator's Manual

The Online Interactive Operator's Manual is currently available in English only.

A PDF version of the Operator's Manual is available for download in multiple languages. Click the link below to view the Operator's Manual in your language. Click "Continue" to view the online version in English.

Get a translated PDF Download Continue

G65 is the command that calls a subroutine with the ability to pass arguments to it. The format follows:

G65 Pnnnn [Lnnnn] [arguments] ;

Arguments italicized in square brackets are optional. See the Programming section for more details on macro arguments.

The G65 command requires a P address corresponding to a program number currently in the control’s memory. When the L address is used the macro call is repeated the specified number of times.

In Example 1, subroutine 1000 is called once without conditions passed to the subroutine. G65 calls are similar to, but not the same as, M98 calls. G65 calls can be nested up to 9 times, which means, program 1 can call program 2, program 2 can call program 3 and program 3 can call program 4.

Example 1:

% G65 P1000 (Call subroutine 1000 as a macro) ; M30 (Program stop) ; O01000 (Macro Subroutine) ; ... M99 (Return from Macro Subroutine) ; %

Be aware: Many service and repair procedures should be done only by authorized personnel. The service technicians at your Haas Factory Outlet (HFO) have the training, experience, and are certified to do these tasks safely and correctly. You should not do machine repair or service procedures unless you are qualified and knowledgeable about the processes.

Danger: Some service procedures can be dangerous or life-threatening. DO NOT attempt a procedure that you do not completely understand. Contact your Haas Factory Outlet (HFO) and schedule a service technician visit if you have any doubts about doing a procedure.