Halting Execution
After all functions in the API buffer have been executed, the API buffer will remain in the Active state and will immediately continue executing functions as they are later added to the buffer. To return the API buffer to Stop state so that API functions in the buffer are not executed until the next time the Execute function is called, call the Halt function.
The Halt function can also be called while the API buffer is still executing functions, in which case the API buffer will stop execution. Any remaining functions in the buffer will be executed the next time the Execute function is called. The Halt function will not stop the operation of any functions that have already been executed by the API buffer; for example, an axis that has started a motion command will not be stopped.
If the Halt function is called specifying an API buffer that is executing the Motion::Wait function, the API buffer will be stopped after the Motion::Wait function completes. To immediately stop the API buffer, use the ApiBuffer::Wait function instead of the Motion::Wait function.