Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: Fred_evans on April 06, 2019, 07:58:02 AM

Title: M98 wont repeat?
Post by: Fred_evans on April 06, 2019, 07:58:02 AM
Hello Chaps
I am using mach 3 and want to check for lost steps.
I wrote the little code attached - but it will only iterate
once??
where did I go wrong?
thanks for the help
best regards
Fred Evans
Title: Re: M98 wont repeat?
Post by: reuelt on April 06, 2019, 08:21:39 AM
Just add M99 at end of subroutine

f100      (faster than possible-mach3 will throttle back)
g21       (mm and absolute)
M98 P1 L5   (RUN SUBROUTINE 5 TIMES)
m30      (rewind and stop)


O1      (letter o - this subroutine must be run 5 times)
g01 z-10   (first position)
g01 z1      (do a feedrate move and move back)
M99   (return to main program)



Title: Re: M98 wont repeat?
Post by: Fred_evans on April 08, 2019, 02:40:41 AM
thank you very much- problem solved!!
regards fred evans