Is this a bug or intended ?
-
@mikedc If you put:
if !move.axes[0].homed || !move.axes[1].homed || !move.axes[2].homed
at the start of homeall.g and indent the rest of the code one space, it'll stop that. -
@stephen6309
Thankyou, ill try that -
@mikedc While the suggestion by @Stephen6309 will work to prevent homing if one or more axes are currently homed, there are a couple of caveats. Firstly, if one axis had been homed but you wanted to home the other axes, then the boolean "or" will prevent you from doing that using homeall.g. Secondly, if you had made some adjustments to the physical position of an end stop or some such, you might at some time want to home the printer even though it has already been homed.
As an alternative suggestion, you could instead use something like this at the beginning of your homeall.g...
if state.status != "processing"
That means if the status does not equal "processing" i.e. a print is not running, then......(carry on with the homing macro).
I'm by no means an expert on conditional gcode so someone more knowledgeable than I might say it won't work - but I use that in one of my trigger macros so I think it will work.
-
This is actually a quite dangerous behaviour. I'm running 2 CNC machines, and on two occasions I've accidentally homed one machine while the other was running. The last time it could have ended quite bad due to the material setup. Now I'm using two different laptops to avoid any incidents. Maybe a checkbox in DWC or a M code to allow or disable manual gcode (or any other source) while the machine is procession a gcode file. With the exception of M112 etc.
-
@rzi The solution deckingman posted above is a good option for when a job is in progress.
-
@phaedrux You can still press a jog button.
-
I like this more and will try it thankyou
-
@rzi said in Is this a bug or intended ?:
@phaedrux You can still press a jog button.
Yes this is true. And I agree that maybe having the option to lock out most DWC controls during a job would be a good idea.
If you have a good idea how something like that could be implemented perhaps you'd like to create a thread for the idea in the DWC wishlist where it can get some feed back.
-
@mikedc said in Is this a bug or intended ?:
I like this more and will try it thankyou
I can't claim much credit as someone else on these forums told me how to do it. I think it was @T3P3Tony . In my case, I had installed a joystick and used triggers to jog the gantries around depending on the state of the 4 switches in the joystick. At the time, triggers could be "fired" even if a print was running and it is very easy to accidentally nudge that joystick. So I needed a mechanism to disable the joystick when a print was running.
-
well its a nice solution, ill be using it in other places too