Hello Guest it is May 14, 2021, 03:33:34 AM

Author Topic: Macro gets stuck in loop, need to restart mach4  (Read 251 times)

0 Members and 1 Guest are viewing this topic.

Macro gets stuck in loop, need to restart mach4
« on: December 17, 2019, 03:46:15 PM »
Hello People,

I made some custom mcodes to run when I want the machine to drill in a panel, so I don't have to make gcodes for every panel. But when something goes wrong and I press stop the mcodes gets stuck in a loop i guess. After that I need to restart Mach4
How do I get the mcode to stop or get out of the loop when something goes wrong? if possible at all.

Thanks in advance.
Kind regards,

Jelle Bos
Re: Macro gets stuck in loop, need to restart mach4
« Reply #1 on: December 17, 2019, 07:29:54 PM »
you must do like "exit point " in each node in yours mcode ,that detect condition(like if stop had been press,or check specific registry that you can control...)and then if its not fill yours condition ,break the loop
one big point i learned on mach4 ,when you press stop ,while m function run ,its not stop the function ,its only stop the movement,so that mean its not only continue run in endless loop ,but also activate yours output if its command in the loop
thanks