Ok.. the normal M66 wait for input is bound to cause some issues as it waits and then... woosh.. the machine will take off.. (yes, I know you can check for the timeout but that actually leads to more coding).. any other machine I have seen, and nearly any device, plc, robot, etc. would never do this.. so I wrote my own m66.. I actually call it m166 to distinguish between the two and ran into the following issue.. I have a While do loop that waits for an input to go high (or low).. and it works fine with one exception... if its waiting and you close Mach4.. well it doesn't actually close.. I'd guess because its still looping and can't stop the thread... so it would be nice if I could do a check and see if M4 is still running, and if not Abort and close. Can't seem to locate any function to return the state of the application.. any suggestions?
thanks, Bob