Help with Macros (On_Abort.ngc
18 Feb 2019 23:54 - 18 Feb 2019 23:54 #126735
by MartyJ
Help with Macros (On_Abort.ngc was created by MartyJ
Based on the
docs here
, I have the following:
on_abort.ngc is in my config folder /macros
This is in my INI:
Basically I want to retract Z on abort.
What I get is on_abort attempting to run continuously, interrupting the interface and unable to home because of errors thrown by continuously trying to run on_abort.ngc
Any ideas where I went wrong?
on_abort.ngc is in my config folder /macros
%
o<on_abort> sub
G28 Z0.0
o<on_abort> endsub
m2
%
This is in my INI:
[RS274NGC]
PARAMETER_FILE = linuxcnc.var
ON_ABORT_COMMAND=O <on_abort> call
SUBROUTINE_PATH = macros
Basically I want to retract Z on abort.
What I get is on_abort attempting to run continuously, interrupting the interface and unable to home because of errors thrown by continuously trying to run on_abort.ngc
Any ideas where I went wrong?
Last edit: 18 Feb 2019 23:54 by MartyJ.
Please Log in or Create an account to join the conversation.
- tommylight
-
- Away
- Moderator
-
Less
More
- Posts: 18563
- Thank you received: 6220
19 Feb 2019 00:28 #126737
by tommylight
Replied by tommylight on topic Help with Macros (On_Abort.ngc
Did not test it but i think this:Should be this:Notice the slash before macros.
[RS274NGC]
PARAMETER_FILE = linuxcnc.var
ON_ABORT_COMMAND=O <on_abort> call
SUBROUTINE_PATH = macros
[RS274NGC]
PARAMETER_FILE = linuxcnc.var
ON_ABORT_COMMAND=O <on_abort> call
SUBROUTINE_PATH = /macros
Please Log in or Create an account to join the conversation.
19 Feb 2019 00:36 - 19 Feb 2019 00:39 #126738
by MartyJ
Replied by MartyJ on topic Help with Macros (On_Abort.ngc
Nice catch. Now it no longer gives errors continuously. Instead it says, "File Not Open". The machine can be homed, it throws occasional "File Not Open" warnings, but doesn't execute the G28 command.
When I run a program and abort it, it says "EOF in file:/(pathtogcodefile)/gcode.ngc seeking o-word: o<on_abort> from line:453"
When I run a program and abort it, it says "EOF in file:/(pathtogcodefile)/gcode.ngc seeking o-word: o<on_abort> from line:453"
Last edit: 19 Feb 2019 00:39 by MartyJ.
Please Log in or Create an account to join the conversation.
19 Feb 2019 00:49 #126741
by MartyJ
Replied by MartyJ on topic Help with Macros (On_Abort.ngc
Thinking about it, all I really need is this.
ON_ABORT_COMMAND=G28 z0.0
Is that a valid usage?
When I try it, I get a "Bad Character '[' used" error.
ON_ABORT_COMMAND=G28 z0.0
Is that a valid usage?
When I try it, I get a "Bad Character '[' used" error.
Please Log in or Create an account to join the conversation.
26 Feb 2019 20:58 #127188
by andypugh
A (rather unexpected) cause of that error is if both the subroutine file and the loaded G-code file have % as top and bottom.
If the subroutine file is %-delimited then try removing them.
Replied by andypugh on topic Help with Macros (On_Abort.ngc
When I run a program and abort it, it says "EOF in file:/(pathtogcodefile)/gcode.ngc seeking o-word: o<on_abort> from line:453"
A (rather unexpected) cause of that error is if both the subroutine file and the loaded G-code file have % as top and bottom.
If the subroutine file is %-delimited then try removing them.
Please Log in or Create an account to join the conversation.
Time to create page: 0.191 seconds