flex_check_move_complete_status

NI-Motion Functions

flex_check_move_complete_status

Device Compatibility

Device Compatibility
7330
Y
7340
Y
7344
Y
7350
Y
7390
Y
NI SoftMotion Controller for CANopen—Xenus
Y
NI SoftMotion Controller for CANopen—Accelnet
Y

Check Move Complete Status

Usage

status = flex_check_move_complete_status(u8 boardID, u8 axisOrVectorSpace, u16 axisOrVSMap, u16* moveComplete);

Purpose

Checks the move complete status for an axis, vector space, group of axes, or group of vector spaces.

Tip  Refer to the Remarks section for information about how the behavior of this function differs between controllers.

Parameters

Name Type Description
boardID u8 assigned by Measurement & Automation Explorer (MAX)
axisOrVectorSpace u8 axis or vector space selector
axisOrVSMap u16 bitmap of axes or vector spaces to check
moveComplete u16* the move complete status

Parameter Discussion

axisOrVectorSpace can select an axis (NIMC_AXIS1 through NIMC_AXIS15), vector space (NIMC_VECTOR_SPACE1 through NIMC_VECTOR_SPACE15), multiple axes (NIMC_AXIS_CTRL), or multiple vector spaces (NIMC_VECTOR_SPACE_CTRL). When simultaneously checking multiple axes or vector spaces, the axisOrVSMap parameter indicates which axes or vector spaces to check. On motion controllers that support fewer than fifteen axes, checking non-existent axes or vector spaces returns error –70006 (NIMC_badResourceIDOrAxisError). Refer to Axes and Vector Spaces for axis and vector space resource IDs.

axisOrVSMap is the bitmap of axes or vector spaces to check. It is only required when multiple axes or vector spaces are selected with the axisOrVectorSpace parameter. Otherwise, this parameter is ignored. NI-Motion ignores additional axes and vector spaces if you select non-existent axes.

When checking multiple axes (axisOrVectorSpace = NIMC_AXIS_CTRL):

D15 ...  D10 D9 D8 D7 D6 D5 D4 D3 D2 D1 D0
Axis 15 ... Axis 10 Axis 9 Axis 8 Axis 7 Axis 6 Axis 5 Axis 4 Axis 3 Axis 2 Axis 1 0

For D1 through D15:
   1 = Move must be complete on specified axis
   0 = Move can be either complete or not complete on specified axis (do not care)

When checking multiple vector spaces (axisOrVectorSpace = NIMC_VECTOR_SPACE_CTRL):

D15 ...  D10 D9 D8 D7 D6 D5 D4 D3 D2 D1 D0
VS 15 ... VS 10 VS 9 VS 8 VS 7 VS 6 VS 5 VS 4 VS 3 VS 2 VS 1 0

For D1 through D15:
   1 = Move must be complete on specified vector space
   0 = Move can be either complete or not complete on specified vector space (do not care)

To check for move complete on a single axis or vector space, set the axisOrVectorSpace selector to the specified axis or vector space. The axisOrVSMap bitmap is ignored.

To check for move complete on multiple axes, the axisOrVectorSpace selector is set to NIMC_AXIS_CTRL and the axisOrVSMap bitmap defines the axes to check. They must all be move complete for the moveComplete output to be true. Similarly, to check for move complete on multiple vector spaces, the axisOrVectorSpace selector is set to NIMC_VECTOR_SPACE_CTRL and the axisOrVSMap bitmap defines the vector spaces to check.

moveComplete indicates if the move is complete on the axes or vector spaces specified.
   1 = Move complete
   0 = Move not complete

Using This Function

This function extends the functionality of Read Trajectory Status such that you can define a combination of axes or coordinate (vector) spaces to check as a group. This function also can check the move complete status for a single axis or coordinate space, much like Read Move Complete Status. Instead of decoding the output of the Read Trajectory Status function yourself, this function does that for you by comparing the axes or vector spaces specified in the axisOrVectorSpace and axisOrVSMap input parameters with the move complete status for the appropriate axes or vector spaces. The output is a single true/false value indicating if the specified move or moves are complete.

This function does not check for following error status or axis off status. Checking for faults during moves is recommended. To do this, use Read per Axis Status, which returns following error and axis off status in addition to the move complete status. Refer to the NI-Motion Help for more information and example code.

Refer to the Read Trajectory Status and Configure Move Complete Criteria functions for more information about move complete status.

Note  Refer to Function Execution Times for benchmark timing information about your controller.

Remarks

This section includes information about how the behavior of this function differs among the controllers that support it.

NI SoftMotion Controller Considerations

The following includes considerations you must make when you are using this function with the NI SoftMotion Controller:

To check the move complete status on axes sixteen through thirty, use the Read per Axis Status function.