Hello Guest it is April 19, 2024, 07:03:10 AM

Author Topic: need help w/ subroutine  (Read 2340 times)

0 Members and 1 Guest are viewing this topic.

need help w/ subroutine
« on: August 17, 2010, 07:43:14 AM »
How do I create a subroutine program for

M8M9
G4P.25

that is repeated many times thruout a program?

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: need help w/ subroutine
« Reply #1 on: August 17, 2010, 08:04:22 PM »
There are several ways to do it.    One is too call the sub from inside the Gcode program . The other way is to call it from  the macro directory


G98 P1 L1              Calls the sub from inside the program.



o1                     This would be the sub code included at the end of the program
M8 M9
G4 P0.25
M99
%


M98 (Name of sub.tap)   would call the sub from the macro directory


'Name of sub.tap               This would be the sub program stored in the macro directory under the name of "Name of Sub.tap"
M8 M9
G4 P0.25
M99
%

Hope that helps,   (;-)