Skip to main content

NRC_RobotMoveJoint(int vel, const NRC_Position& target, int acc, int dec)

Robot point-to-point motion

The robot moves from the current position to the target position in a point-to-point manner at a velocity of vel

Before calling this function, please power on the servo by calling the NRC_ServoEnable() function

After this function is successfully called, the robot will start moving. Please pay attention to safety

Type

int=>Robot point-to-point motion

Return valueDescription
0The function is called successfully
-101Invalid input parameter
-102The target object does not exist. This typically occurs when the system initialization is incomplete, and calling other functions may return this value
-103The target object is currently in an inoperable state

Parameter Option

ParameterTypeDescription
velintThe running speed of the robot, as the percentage of the maximum speed of the robot. Parameter range: 0 < vel <= 100
targetNRC_Position&Robot motion target position
accintRobot running acceleration, as a percentage of the maximum acceleration of each joint of the robot. Parameter range: 0 < acc <= 100
decintRobot running deceleration, as a percentage of the maximum deceleration of each joint of the robot. Parameter range: 0 < dec <= 100

Sample code

NRC_Position target={NRC_ACS,10,10,10,10,10,10};
NRC_RobotMoveJoint(50, target, 50, 50);
//Perform a point-to-point movement to the target position with a velocity of 50%, acceleration of 50% , and deceleration of 50%