Checking for axis limit hit during Jog or Move
Posted: Tue Sep 07, 2021 12:39 am
Hi,
I'm sure there is a simple answer to this, but I haven't been able to find a discussion that relates to this question. The question is in regard to my Kflop C programs that Jog to a external signal such as a probe detection. For a probe Jog, my while loop implements a timeout along with the ReadBit for the probe input. For a probe Move, there is also a check for an unexpected probe trigger as well as a timeout. These goes a long way in protecting the probe from a bone-headed operator (that being me).
The reason for the timeout in the Jog while loop is to handle the probe missing its target. In the Move, the timeout is mainly used to exit the while loop if a limit is hit .
I'd like to be able to directly check for hitting an axis limit switch or soft limit. Is there a way to pole for the axis being stopped due to hitting a limit or anything else that can stop the motion during a Jog or a Move?
I'm using version 4.3.5f
I'm sure there is a simple answer to this, but I haven't been able to find a discussion that relates to this question. The question is in regard to my Kflop C programs that Jog to a external signal such as a probe detection. For a probe Jog, my while loop implements a timeout along with the ReadBit for the probe input. For a probe Move, there is also a check for an unexpected probe trigger as well as a timeout. These goes a long way in protecting the probe from a bone-headed operator (that being me).
The reason for the timeout in the Jog while loop is to handle the probe missing its target. In the Move, the timeout is mainly used to exit the while loop if a limit is hit .
I'd like to be able to directly check for hitting an axis limit switch or soft limit. Is there a way to pole for the axis being stopped due to hitting a limit or anything else that can stop the motion during a Jog or a Move?
I'm using version 4.3.5f