forcedimension_core.drd.direct module

forcedimension_core.drd.direct.getPositionAndOrientation(p_out: SupportsPtrs3[c_double], o_out: SupportsPtrs3[c_double], pg_out: c_double, matrix_out: SupportsPtr[c_double], ID: int = -1) int[source]

Retrieve the position (in [m]) about the X, Y, and Z axes, the angle of each joint (in [rad]), (if applicable) the gripper position (in [m]), and orientation frame matrix of the end-effector. Please refer to your device user manual for more information on your device coordinate system.

Note

Unlike forcedimension_core.dhd.getPositionAndOrientation(), this function returns immediately. It loads from an internal buffer that is refreshed by the robotic control loop. For more information about regulation see Regulation.

Parameters:
Raises:
Returns:

0 or forcedimension_core.constants.TIMEGUARD on success, -1 otherwise.

forcedimension_core.drd.direct.getVelocity(v_out: SupportsPtrs3[c_double], w_out: SupportsPtrs3[c_double], vg_out: c_double, ID: int = -1) int[source]

Retrieve the linear velocity of the end-effector (in [m/s]) as well as the angular velocity (in [rad/s]) about the X, Y, and Z axes. Please refer to your device user manual for more information on your device coordinate system.

Note

Unlike forcedimension_core.dhd.getLinearVelocity(), forcedimension_core.dhd.getAngularVelocityRad(), and forcedimension_core.dhd.getAngularVelocityDeg() this function returns immediately. It loads from an internal buffer that is refreshed by the robotic control loop. For more information about regulation see Regulation.

Parameters:
Raises:
Returns:

0 on success and -1 otherwise.

forcedimension_core.drd.direct.moveTo(pos: SupportsPtr[c_double], block: bool, ID: int = -1)[source]

Send the robot end-effector to a desired Cartesian 7-DOF configuration. The motion uses smooth acceleration/deceleration. The acceleration and velocity profiles can be controlled by adjusting the trajectory generation parameters.

Note

The paths generated by this function are not guarunteed to be continuous if a command is interrupted by another call to this function while still in the process of being executed. If you want to guaruntee continuity use forcedimension_core.drd.track(). For more information see Regulation.

Parameters:
  • pos (SupportsPtr[ctypes.c_double]) – Buffer of target positions/orientations for each DOF. DOFs 0-2 correspond to position about the X, Y, and Z axes (in [m]). DOFs 3-6 correspond to the target orientation about the first, second and third joints (in [rad]). DOF 7 corresponds to the gripper gap (in [m]).

  • block (bool) – If True, the call blocks until the destination is reached. If False, the call returns immediately.

  • ID (int) – Device ID (see Support for Multiple Devices section for details).

Raises:
Returns:

0 on success, and -1 otherwise.

forcedimension_core.drd.direct.moveToAllEnc(enc: SupportsPtr[c_int], block: bool, ID: int = -1)[source]

Send the robot end-effector to a desired encoder position. The motion follows a straight line in the encoder space, with smooth acceleration/deceleration. The acceleration and velocity profiles can be controlled by adjusting the trajectory generation parameters.

Note

The paths generated by this function are not guarunteed to be continuous if a command is interrupted by another call to this function while still in the process of being executed. If you want to guaruntee continuity use forcedimension_core.drd.trackAllEnc(). For more information see Regulation.

Parameters:
Raises:
Returns:

0 on success, and -1 otherwise.

forcedimension_core.drd.direct.track(pos: SupportsPtr[c_double], ID: int = -1)[source]

Send the robot end-effector to a desired Cartesian 7-DOF configuration. If motion filters are enabled, the motion follows a smooth acceleration/deceleration. The acceleration and velocity profiles can be controlled by adjusting the trajectory generation parameters.

Note

For more information see Regulation.

Parameters:
  • pos (SupportsPtr[ctypes.c_double]) – Buffer of target positions/orientations for each DOF. DOFs 0-2 correspond to position about the X, Y, and Z axes (in [m]). DOFs 3-6 correspond to the target orientation about the first, second and third joints (in [rad]). DOF 7 corresponds to the gripper gap (in [m]).

  • ID (int) – Device ID (see Support for Multiple Devices section for details).

Raises:
Returns:

0 on success, and -1 otherwise.

forcedimension_core.drd.direct.trackAllEnc(enc: SupportsPtr[c_int], ID: int = -1)[source]

Send the robot end-effector to a desired encoder position. If motion filters are enabled, th emotion follows a smooth acceleration/deceleration constraint on each encoder axis. The acceleration and velocity profiles can be controlled by adjusting the trajectory generation parameters.

Note

For more information see Regulation.

Parameters:
Raises:
Returns:

0 on success, and -1 otherwise.