Events that cause deliberate disconnect should be configurable (ALERT / ERROR)
Hey Patrick,
I'm trying to work out what events cause a disconnect and how to change that behavior in cnc-gcode-controller.
Specifically, one of the issues is that upon certain reconnect attempts the software sends a GRBL reset command which causes GRBL to execute the start-up sequence stored in $N - regardless of where the machine currently is. On GRBL's side, I assume that's a desired behavior even though it only causes issues on my end. I already broke multiple endmills because I wasn't quick enough on my E-STOP.
In general, disconnecting upon ERROR or ALERT should be configurable. I haven't found a single instance where a disconnect had a desirable effect on my workflow. I pretty much always simply reconnect and then have to set up everything again, trying to avoid the aforementioned reset sequence that pops up only every so often instead of a complete GRBL LOCK wakeup (which is what I would expect when connecting every time) that requires $H homing before allowing anything else.
I found multiple places where a reset or disconnect is triggered but I can't work out the code workflow how this is implemented. Can you please give me some pointers?