Skip to content

Robotic Arm APIs

The robotic arm APIs are implemented by the following classes. You can find the corresponding header files in the c++\include\drivers\arm directory to access the complete set of APIs.

Header FileClass NameDescription
arm_factory.hArmFactoryA factory class for creating robotic arm instances of different types.
arm_interface.hArmInterfaceThe base interface class defining common APIs for robotic arm control. All vendor-specific drivers should inherit from this class.

There are three ways to create a robotic arm instance.

  1. Create a robotic arm instance by specifying the type and name.

    • Method:

      static std::shared_ptr<ArmInterface> create_arm(
      const std::string& arm_type,
      const std::string& name,
      const std::unordered_map<std::string, std::string>& params);
    • Parameters:

      Parameter
      Type
      Description
      arm_typeInputThe manufacturer or type of the robotic arm.
      nameInputThe instance identifier for the arm (e.g., "left_arm", "right_arm").
      paramsInputA key-value map for additional configuration parameters (e.g., {{"ip", "192.168.1.18"}, {"port", "8080"}}).
    • Return Value:

      Returns a shared pointer to an object of a class derived from ArmInterface if the instance is created successfully; otherwise, returns nullptr.

  2. Create a robotic arm instance by arm parameters.

    • Method:

      static std::shared_ptr<ArmInterface> create_arm(const ArmFactoryParam& param)
    • Parameter:

      Parameter
      Type
      Description
      paramInputParameters related to the robotic arm. For details, please refer to ArmFactoryParam.
    • Return Value:

      Returns a shared pointer to an object of a class derived from ArmInterface if the instance is created successfully; otherwise, returns nullptr.

  3. Create a robotic arm instance from a configuration file.

    • Method:

      static std::shared_ptr<ArmInterface> create_arm_from_config(
      const std::string& config_path)
    • Parameters:

      ParameterTypeDescription

      config_path

      Input

      Path to the configuration file. The configuration file must be a JSON file.

      {
      "arm_type":"xxx", # Robotic arm vendor
      "arm_name":"left_arm", # Robotic arm name
      "ip": "192.168.1.18", # TCP IP address
      "port": "8080", # TCP port number
      "udp_ip": "192.168.1.102", # UDP IP address
      "udp_port": "8089", # UDP port number
      "udp_cycle": "1", # UDP cycle (period = udp_cycle * 5 ms)
      "enable_gripper": "false" # Enable gripper
      }
    • Return Value:

      Returns a shared pointer to an object of a class derived from ArmInterface if the instance is created successfully; otherwise, returns nullptr.

After creating a robotic arm instance, you can establish a connection to the robotic arm using the following method.

  • Method:

    AbcErrorCode connect()
  • Return Value:

    AbcErrorCode::SUCCESS indicates that the connection was established successfully. For other error codes, please refer to AbcErrorCode.

You can disconnect from the robotic arm using the following method.

  • Method:

    AbcErrorCode disconnect()
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

Robotic arm trajectory control includes motion control and pass-through control.

  • Motion Control: This includes joint motion, Cartesian linear motion, and Cartesian space motion.
  • Pass-through Control: This involves angle pass-through and pose pass-through.

In joint space, a motion trajectory is planned to drive each joint of the robotic arm to the specified target joint positions.

  • Method:

    AbcErrorCode move_joint_position(
    const std::vector<AbcType>& joints,
    int v,
    int r,
    int trajectory_connect,
    int block)
  • Parameters:

    Parameter
    Type
    Description
    jointsInputTarget joint positions, in degrees. For details, please refer to AbcType.
    vInputPercentage of the maximum joint linear velocity and acceleration used for planning. Valid range: 0–100.
    rInputTrajectory blending radius. Default value is 0.
    trajectory_connectInputTrajectory connection flag. Accepts 0 or 1.
    - 0: Plan and execute the trajectory immediately. Do not connect to the next trajectory.
    - 1: Plan the current trajectory together with the next one, but do not execute immediately. Note: In blocking mode, the method returns immediately even after the trajectory is successfully sent.
    blockInputBlocking mode flag. Accepts 0 or 1.
    - 0: Non-blocking mode. The method returns immediately after successfully sending the motion command to the controller.
    - 1: Blocking mode. The method waits until the arm completes the motion or an error occurs before returning.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

In Cartesian space, a linear motion trajectory is planned to move the robotic arm along a straight line to the specified target pose.

  • Method:

    AbcErrorCode move_cartesian_linear(
    const AbcPose& pose,
    int v,
    int r,
    int trajectory_connect,
    int block)
  • Parameters:

    Parameter
    Type
    Description
    poseInputTarget pose. For details, please refer to AbcPose.
    vInputPercentage of the maximum joint linear velocity and acceleration used for planning. Valid range: 0–100.
    rInputTrajectory blending radius. Default value is 0.
    trajectory_connectInputTrajectory connection flag. Accepts 0 or 1.
    - 0: Plan and execute the trajectory immediately. Do not connect to the next trajectory.
    - 1: Plan the current trajectory together with the next one, but do not execute immediately. Note: In blocking mode, the method returns immediately even after the trajectory is successfully sent.
    blockInputBlocking mode flag. Accepts 0 or 1.
    - 0: Non-blocking mode. The method returns immediately after successfully sending the motion command to the controller.
    - 1: Blocking mode. The method waits until the arm completes the motion or an error occurs before returning.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

In joint space, a motion trajectory is planned to move the robotic arm to the specified target pose.

  • Method:

    AbcErrorCode move_joint_pose(
    const AbcPose& pose,
    int v,
    int r,
    int trajectory_connect,
    int block)
  • Parameters:

    Parameter
    Type
    Description
    poseInputTarget pose. For details, please refer to AbcPose.
    vInputPercentage of the maximum joint angular velocity and joint angular acceleration used for planning. Valid range: 0–100.
    rInputTrajectory blending radius. Default value is 0.
    trajectory_connectInputTrajectory connection flag. Accepts 0 or 1.
    - 0: Plan and execute the trajectory immediately. Do not connect to the next trajectory.
    - 1: Plan the current trajectory together with the next one, but do not execute immediately. Note: In blocking mode, the method returns immediately even after the trajectory is successfully sent.
    blockInputBlocking mode flag. Accepts 0 or 1.
    - 0: Non-blocking mode. The method returns immediately after successfully sending the motion command to the controller.
    - 1: Blocking mode. The method waits until the arm completes the motion or an error occurs before returning.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

Joint angles are sent to the robotic arm via CAN FD (Controller Area Network Flexible Data-rate), bypassing trajectory planning by the controller. If the method is called correctly, the robotic arm executes the motion immediately.

  • Method:

    AbcErrorCode move_joint_position_canfd(
    const std::vector<AbcType>& joints,
    bool follow,
    int trajectory_mode = 0,
    int radio = 0)
  • Parameters:

    Parameter
    Type
    Description
    jointsInputTarget joint positions, in degrees. For details, please refer to AbcType.
    followInputFollow mode flag. Accepts true or false.
    - true: High-follow mode.
    - false: Low-follow mode.
    Note: High-follow mode requires a pass-through cycle of 10ms or less.
    trajectory_modeInput (optional)Used in high-follow mode. Accepts 0, 1, or 2.
    - 0: Full pass-through mode.
    - 1: Curve-fitting mode.
    - 2: Filtering mode.
    radioInput (optional)- In curve-fitting mode: radio is the smoothing coefficient, range 0–100.
    - In filtering mode: radio is the filter parameter, range 0–1000.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

Angle Pass-through with Collision Avoidance

Section titled “Angle Pass-through with Collision Avoidance”

This method extends move_joint_position_canfd() by adding collision avoidance functionality. If the robotic arm is at risk of colliding with the robot body, the motion will not be executed.

  • Method:

    AbcErrorCode move_joint_position_canfd_collision_avoid(
    const std::vector<AbcType>& arm_joints,
    const std::vector<AbcType>& torso_head_joints,
    bool follow,
    int trajectory_mode = 0,
    int radio = 0)
  • Parameters:

    Parameter
    Type
    Description
    arm_jointsInputTarget joint positions for the robotic arm, in degrees. For details, please refer to AbcType.
    torso_head_jointsInputJoint angles for the torso and head, in degrees.
    followInputFollow mode flag. Accepts true or false.
    - true: High-follow mode.
    - false: Low-follow mode.
    Note: High-follow mode requires a pass-through cycle of 10ms or less.
    trajectory_modeInput (optional)Used in high-follow mode. Accepts 0, 1, or 2.
    - 0: Full pass-through mode.
    - 1: Curve-fitting mode.
    - 2: Filtering mode.
    radioInput (optional)- In curve-fitting mode: radio is the smoothing coefficient, range 0–100.
    - In filtering mode: radio is the filter parameter, range 0–1000.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

The target pose is sent to the robotic arm via CAN FD (Controller Area Network Flexible Data-rate), bypassing trajectory planning by the controller.

When the target pose is received by the arm controller, the controller first attempts inverse kinematics calculation. If the inverse kinematics solution succeeds and the calculated joint angles do not differ significantly from the current joint positions, the angles are sent directly to the joints for execution, skipping additional trajectory planning.

This feature is suitable for scenarios that require periodic pose adjustments, such as visual servoing applications.

  • Method:

    AbcErrorCode move_cartesian_pose_canfd(
    const AbcPose& pose,
    bool follow,
    int trajectory_mode = 0,
    int radio = 0)
  • Parameters:

    Parameter
    Type
    Description
    poseInputTarget pose. For details, please refer to AbcPose.
    followInputFollow mode flag. Accepts true or false.
    - true: High-follow mode.
    - false: Low-follow mode.
    Note: High-follow mode requires a pass-through cycle of 10ms or less.
    trajectory_modeInput (optional)Used in high-follow mode. Accepts 0, 1, or 2.
    - 0: Full pass-through mode.
    - 1: Curve-fitting mode.
    - 2: Filtering mode.
    radioInput (optional)- In curve-fitting mode: radio is the smoothing coefficient, range 0–100.
    - In filtering mode: radio is the filter parameter, range 0–1000.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

Joint space following motion refers to real-time trajectory planning in joint space to achieve dynamic following of target joint positions.

  • Method:

    AbcErrorCode move_joint_follow(std::vector<AbcType>& joints)
  • Parameter:

    Parameter
    Type
    Description
    jointsInputTarget joint positions. For details, please refer to AbcType.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

Cartesian space following motion refers to real-time trajectory planning in Cartesian space to achieve dynamic following of the target pose.

  • Method:

    AbcErrorCode move_pose_follow(const AbcPose& pose)
  • Parameter:

    Parameter
    Type
    Description
    poseInputTarget pose. For details, please refer to AbcPose.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

  • Method:

    AbcErrorCode get_joint_degree(std::vector<AbcType>& joints)
  • Parameter:

    Parameter
    Type
    Description
    jointsOutputCurrent joint angles. For details, please refer to AbcType.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

This SDK provides a set of algorithm-related APIs for the robotic arm, including forward kinematics and inverse kinematics.

  • Method:

    AbcErrorCode forward_kinematics(
    const std::vector<AbcType>& joints,
    AbcPose& pose)
  • Parameters:

    Parameter
    Type
    Description
    jointsInputJoint angles. For details, please refer to AbcType.
    poseOutputPose computed by forward kinematics. For details, please refer to AbcPose.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

  • Method:

    AbcErrorCode inverse_kinematics(
    const AbcPose& pose,
    const std::vector<AbcType>& ref_joints,
    std::vector<AbcType>& joints,
    int mode = 0)
  • Parameters:

    Parameter
    Type
    Description
    poseInputThe target pose. For details, please refer to AbcPose.
    ref_jointsInputReference joint angles. For details, please refer to AbcType.
    jointsOutputJoint angles computed by inverse kinematics. For details, please refer to AbcType.
    modeInput (optional)Solution mode. Accepts 0 or 1. Default is 0.
    - 0: Single-step solution.
    - 1: Iterative search solution.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

This SDK supports basic motion control operations for the robotic arm, including slow stop, emergency stop, pause, and resume.

The robotic arm decelerates and stops smoothly along the currently executing trajectory.

  • Method:

    AbcErrorCode set_arm_slow_stop()
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

The robotic arm stops immediately at the maximum joint speed along the currently executing trajectory. This operation is an irreversible abort; motion cannot be resumed from the interruption point.

  • Method:

    AbcErrorCode set_arm_stop()
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

The robotic arm pauses execution along the currently running trajectory. This operation is a recoverable interruption; motion can be resumed from the point of interruption.

  • Method:

    AbcErrorCode set_arm_pause()
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

After being paused, the robotic arm resumes execution from the interruption point and continues the unfinished motion task.

  • Method:

    AbcErrorCode set_arm_continue()
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

  • Method:

    AbcErrorCode set_plus_mode(int mode)
  • Parameter:

    Parameter
    Type
    Description
    modeInputThe end-effector ecosystem protocol mode.
    - 0: Disable protocol.
    - 9600: Enable protocol (baud rate 9600).
    - 115200: Enable protocol (baud rate 115200).
    - 256000: Enable protocol (baud rate 256000).
    - 460800: Enable protocol (baud rate 460800).
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

The gripper moves to its fully open position at the specified speed.

  • Method:

    AbcErrorCode set_gripper_release(int speed, bool block, int timeout)
  • Parameters:

    Parameter
    Type
    Description
    speedInputGripper release speed. Valid range: 1–1000 (dimensionless).
    blockInputBlocking mode flag.
    - true: Blocking mode. Waits for the controller to confirm the gripper has reached the position.
    - false: Non-blocking mode. Does not wait for the gripper-in-position feedback.
    timeoutInputTimeout behavior depends on the blocking mode.
    - Blocking mode: Maximum waiting time for the gripper to reach the target position, in seconds.
    - Non-blocking mode: If set to 0, the method returns immediately after sending the command; otherwise, it returns after receiving the successful setting command.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

The gripper grasps at the specified speed and force. Grasping stops automatically when the gripping force exceeds the configured force threshold.

  • Method:

    AbcErrorCode set_gripper_pick(int speed, int force, bool block, int timeout)
  • Parameters:

    Parameter
    Type
    Description
    speedInputGripper closing speed. Valid range: 1–1000 (dimensionless).
    forceInputForce-control threshold. Valid range: 50–1000 (dimensionless).
    blockInputBlocking mode flag.
    - true: Blocking mode. Waits for the controller to confirm the gripper has reached the position.
    - false: Non-blocking mode. Does not wait for the gripper-in-position feedback.
    timeoutInputTimeout behavior depends on the blocking mode.
    - Blocking mode: Maximum waiting time for the gripper to reach the target position, in seconds.
    - Non-blocking mode: If set to 0, the method returns immediately after sending the command; otherwise, it returns after receiving the successful setting command.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

The gripper performs continuous force-controlled grasping, maintaining the gripping force at the specified level during operation.

  • Method:

    AbcErrorCode set_gripper_pick_on(int speed, int force, bool block, int timeout)
  • Parameters:

    Parameter
    Type
    Description
    speedInputGripper closing speed. Valid range: 1–1000 (dimensionless).
    forceInputForce-control threshold. Valid range: 50–1000 (dimensionless).
    blockInputBlocking mode flag.
    - true: Blocking mode. Waits for the controller to confirm the gripper has reached the position.
    - false: Non-blocking mode. Does not wait for the gripper-in-position feedback.
    timeoutInputTimeout behavior depends on the blocking mode.
    - Blocking mode: Maximum waiting time for the gripper to reach the target position, in seconds.
    - Non-blocking mode: If set to 0, the method returns immediately after sending the command; otherwise, it returns after receiving the successful setting command.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

After the gripper reaches the target position, the following behavior applies:

  • If the current aperture is smaller than the target, the gripper opens to the target position at the default speed.

  • If the current aperture is larger than the target, the gripper closes towards the target position at the specified speed and torque limit. The gripper stops when either the torque threshold is exceeded or the target position is reached.

  • Method:

    AbcErrorCode set_gripper_position(int position, bool block, int timeout)
  • Parameters:

    Parameter
    Type
    Description
    positionInputTarget gripper aperture position. Valid range: 1–1000 (dimensionless).
    blockInputBlocking mode flag.
    - true: Blocking mode. Waits for the controller to confirm the gripper has reached the position.
    - false: Non-blocking mode. Does not wait for the gripper-in-position feedback.
    timeoutInputTimeout behavior depends on the blocking mode.
    - Blocking mode: Maximum waiting time for the gripper to reach the target position, in seconds.
    - Non-blocking mode: If set to 0, the method returns immediately after sending the command; otherwise, it returns after receiving the successful setting command.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

  • Method:

    AbcErrorCode get_gripper_state(AbcGripperState* state)
  • Parameter:

    Parameter
    Type
    Description
    stateOutputThe current gripper status. For details, please refer to AbcGripperState.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

Set Target Gesture Sequence Number of the Dexterous Hand

Section titled “Set Target Gesture Sequence Number of the Dexterous Hand”
  • Method:

    AbcErrorCode set_hand_posture(
    int posture_num, bool block,
    int timeout)
  • Parameters:

    Parameter
    Type
    Description
    posture_numInputGesture sequence number pre-stored in the dexterous hand, range: 1-40.
    blockInput- true indicates blocking mode, which waits until the dexterous hand motion completes before returning.
    - false indicates non-blocking mode, which returns immediately after the command is sent.
    timeoutInputTimeout value in blocking mode, in seconds.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

The dexterous hand has 6 degrees of freedom (DOF), numbered 1–6 as follows:

1: Little finger, 2: Ring finger, 3: Middle finger, 4: Index finger, 5: Thumb flexion, 6: Thumb rotation.

  • Method:

    AbcErrorCode set_hand_angle(const std::vector<int>& hand_angle)
  • Parameter:

    Parameter
    Type
    Description
    hand_angleInputArray of finger angles. The array length is 6. The angle range is 0–1000. Additionally, -1 indicates that no action will be performed for this degree of freedom, and the current state will be maintained.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

Set Angle Following Control for the Dexterous Hand

Section titled “Set Angle Following Control for the Dexterous Hand”

The dexterous hand has 6 degrees of freedom (DOF), numbered 1–6 as follows:

1: Little finger, 2: Ring finger, 3: Middle finger, 4: Index finger, 5: Thumb flexion, 6: Thumb rotation.

  • Method:

    AbcErrorCode set_hand_follow_angle(
    const std::vector<int>& hand_angle,
    int block)
  • Parameters:

    Parameter
    Type
    Description
    hand_angleInputArray of finger angles. The array length is 6. The angle range is defined by the dexterous hand manufacturer (e.g., for INSPIRE-ROBOTS, the range is 0–2000).
    blockInputTimeout value before returning, in milliseconds. A value of 0 means non-blocking mode.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

Set Position Following Control for the Dexterous Hand

Section titled “Set Position Following Control for the Dexterous Hand”

The dexterous hand has 6 degrees of freedom (DOF), numbered 1–6 as follows:

1: Little finger, 2: Ring finger, 3: Middle finger, 4: Index finger, 5: Thumb flexion, 6: Thumb rotation.

  • Method:

    AbcErrorCode set_hand_follow_pos(
    const std::vector<int>& hand_pos,
    int block)
  • Parameters:

    Parameter
    Type
    Description
    hand_angleInputArray of finger positions. The array length is 6. The position range is defined by the dexterous hand manufacturer (e.g., for INSPIRE-ROBOTS, the range is 0–1000).
    blockInputTimeout value before returning, in milliseconds. A value of 0 means non-blocking mode.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

  • Method:

    AbcErrorCode set_hand_speed(int speed)
  • Parameter:

    Parameter
    Type
    Description
    speedInputFinger speed. Valid range: 1–1000.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

  • Method:

    AbcErrorCode set_hand_force(int hand_force)
  • Parameter:

    Parameter
    Type
    Description
    hand_forceInputFinger force. Valid range: 1–1000.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

After the robotic arm is started, you must first call the following method to configure Modbus RTU mode before performing any operation on the communication port. Otherwise, an error will be returned.

The robotic arm persists the Modbus configuration. After a reboot, the arm automatically restores the mode that was configured before power-off.

  • Method:

    AbcErrorCode set_modbus_mode(int port, int baudrate, int timeout)
  • Parameters:

    Parameter
    Type
    Description
    portInputSpecifies the communication port. Valid values: 0, 1, or 2.
    - 0: Controller RS485 port as RTU master.
    - 1: End interface board RS485 port as RTU master.
    - 2: Controller RS485 port as RTU slave.
    baudrateInputBaud rate, supporting three common baud rates, namely 9600, 115200, and 460800.
    timeoutInputTimeout period, in 100 ms. For all read and write commands to the Modbus device, if no response data is returned within the specified timeout period, a timeout error will be returned. The timeout period cannot be set to 0; if set to 0, the robotic arm will take it as 1 for configuration.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

  • Method:

    AbcErrorCode close_modbus_mode(int port)
  • Parameter:

    Parameter
    Type
    Description
    portInputSpecifies the communication port. Valid values: 0, 1, or 2.
    - 0: Controller RS485 port as RTU master.
    - 1: End interface board RS485 port as RTU master.
    - 2: Controller RS485 port as RTU slave.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

  • Method:

    AbcErrorCode write_registers(
    const PeripheralReadWriteParams& params,
    const std::vector<uint8_t>& data)
  • Parameters:

    Parameter
    Type
    Description
    paramsInputParameter structure writing multiple registers. This method can write up to 10 registers once, that is, the value of the num member must not exceed 10. For details, please refer to PeripheralReadWriteParams.
    dataInputData array to write to register.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

This SDK provides an interface for active reporting of robotic arm status.

Within the same local area network (LAN), by configuring UDP active reporting and registering a robotic arm status callback function, the application can receive periodic robotic arm status data at a specified interval (default: 5 ms).

  • Method:

    AbcErrorCode realtime_arm_state_set_configuration(const RealtimePushConfig& config)
  • Parameter:

    Parameter
    Type
    Description
    configInputUDP configuration. For details, please refer to RealtimePushConfig.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

Register Robotic Arm State Callback Function

Section titled “Register Robotic Arm State Callback Function”
  • Method:

    void realtime_arm_state_call_back(AbcArmRealtimeStateCallback realtime_callback)
  • Parameter:

    Parameter
    Type
    Description
    realtime_callbackInputAbcArmRealtimeStateCallback is a function pointer type. For details, please refer to AbcArmRealtimeStateCallback. The callback function is called whenever a robotic arm state update is received.
  • Return Value:

    None (void).

  • Method:

    AbcErrorCode get_error_flag(
    std::vector<uint16_t>& err_flag,
    std::vector<uint16_t>& brake_state)
  • Parameters:

    Parameter
    Type
    Description
    err_flagOutputJoint error codes.
    brake_stateOutputJoint brake status.
    - 1: Brake is engaged (not released).
    - 0: Brake is released.
  • Return Value:

    AbcErrorCode::SUCCESS indicates success. For other error codes, please refer to AbcErrorCode.

  • Method:

    std::string get_name() const
  • Return Value:

    The name of the robotic arm instance.