M98 of Invalid Macro (axes not homed) does not error (HTTP)
-
I've got a SBC+MB6HC machine which I'm sending commands to via the
POST /machine/code
http request. Everything is running 3.5.1 stable.My config.g has a
M564 S1 H1
in it to keep the axes from being moved until homing is complete.
This means that if I send a command likeG0 X436.5 Y-105.3 Z5
from the console or an http request, I get the correct error back:Error: G0: insufficient axes homed
.
However, when I have a macro/macros/test_limit_macro.g
withG0 X436.5 Y-105.3 Z5
as the contents, runningM98 P"/macros/test_limit_macro.g"
in the console returns the red error line plus a green bar as if the command completed successfully. In addition, runningM98 P"/macros/test_limit_macro.g"
via http returns an empty string result as if the command completed successfully.Is this intended? If so it makes it hard to raise a meaningful error in the program that is making the http requests.
If its not a bug, are there any workarounds or alternatives to be able to extract the error output when running a macro via http request?
Cheers,
T -
@tristanryerparke Yes, that is intended.
M98
starts the macro successfully but only as soon as the following action fails you get a generic error message. You need to subscribe to the object model to keep track of incoming messages, then you can handle that as well. See here for further API details. -
This post is deleted!