Hi,
on a large industrial machine having an Estop completely and imediately stop Mach is probably not safe at all.
You might need time for the spindle to de-accelerate, then the Z axis brake come on before the Zaxis motor is depowered
or risk having the 1000kg spindle head slump down on to the table and risk crushing the operator who is already in some
sort of trouble hence the Estop.
I suspect to have your Estop button disable Mach4 as you are acustomed to in Mach3 you will have to place a couple of lines
of Lua code in your signal script.
Mach4 signals are handled quite differently than they were in Mach3. In Mach4 any time a signal changes the signal script runs.
There are many hundreds of signals, including input/output signals, Estop for example but many many more inside Mach itself.
When the signal script runs all that is known that a signal has changed. The script runs through a list of signals you are interested in to
see if any one of them has changed and if so what it changed to.
To enact the behaviour you want you will need to put some code in the signal script that achieves the following logic:
1) Has the Estop signal changed?
2) If it has, is it now active?
3) if its active execute an API call to disable Mach4
I know it seems a bit weird that you have to program Mach4 to disable when an Estop occurrs but it is a consequence of the need
for OEM machine builders to have the felxibility to have some specific behaviour that their machine needs to be safe. Whatever
may be said about Mach4 is that it great strength is the flexibility with which it can be programmed and its greastest weakness
is that its so flexible that it can make it tricky to do ordinary stuff.
A signal like Estop is a perfect example...you might think that if you activate that signal a certain function would happen
automatically...it doesn't. You have to decide and program the function you wish to have happen. Don't be too alarmed,
once you get used to thinking that way, namely a signal object is distinct from its function or action it gets a lot easier.
I will help and I'm sure others will chime in to help as well with the actual code.
Craig