MotionController Axis MultiAxis IO IOPoint NetworkNode RsiError
Sample Apps Changelog

RapidCode API

◆ MotionHoldTypeSet()

void MotionHoldTypeSet ( RSIMotionHoldType  type)
pure virtual

Set the motion hold type.

Description:
MotionHoldTypeSet sets the motion hold type.
Parameters
typeUse RSIMotionAttrHoldType.
Sample Code:
// configure the next move to wait for a gate to be cleared
axis->MotionHoldTypeSet(RSIMotionAttrHoldTypeGATE);
Note
To hold execution of motion, you can use Motion Hold.

If you need to hold execution based on a particular bit turning ON or OFF, use RSIMotionAttrHoldTypeUSER_ADDRESS. With RSIMotionAttrHoldTypeUSER_ADDRESS, the logic in the MotionController firmware goes something like this:

andResult = ( userAddressValue & mask);
if(andResult == pattern)
releaseHold();

If using RSIMotionAttrHoldTypeUSER_ADDRESS or GATE, be sure to set RSIMotionAttrMaskHOLD before starting motion.

If using RSIMotionAttrHoldTypeAXIS_POSITION_COMMAND be sure to set RSIMotionAttrMaskHOLD or LESS before starting motion.

See also
MotionHoldTypeGet
 
Examples
MotionHoldReleasedByDigitalInput.cpp, MotionHoldReleasedByDigitalInput.cs, MotionHoldReleasedByPosition.cpp, MotionHoldReleasedByPosition.cs, MotionHoldReleasedBySoftwareAddress.cpp, and MotionHoldReleasedBySoftwareAddress.cs.