set_user_home (Manual Mode)

This section explains how to use set_user_home during Manual (Teach) operations. It defines a custom home position (pose) that the robot can return to for standby, calibration, or safety recovery. The user home is typically set after manually jogging the robot to a known, safe posture (e.g., fully extended or folded position).

Typical usage

  • Define a “safe standby” pose at the end of a manual teaching session.

  • Store a repeatable reference position for quick homing or calibration checks.

  • Update the home position after a tool change or fixture repositioning.

Note

  • The home position is stored in the controller and persists after reboot.

  • The pose should be reachable under all safety configurations.

  • Retrieve the stored pose anytime using get_user_home.

Example: Define a Custom Home Pose After Manual Teaching

// Step 1. Jog robot to the desired "home" posture manually
printf("Position robot at desired home location...\n");
std::this_thread::sleep_for(std::chrono::seconds(3)); // Operator moves manually

// Step 2. Set the current pose as the new user home position
drfl.set_user_home();

printf("New User Home successfully set.\n");

// Step 3. (Optional) Verify by reading it back
LPROBOT_POSE pHome = drfl.get_user_home();
if (pHome != NULL) {
    printf("[Stored User Home]\n");
    for (int i = 0; i < NUMBER_OF_JOINT; ++i)
        printf("J%d [deg]: %.2f\n", i + 1, pHome->_fPosition[i]);
}

Tips

  • Choose a collision-free and easily reachable pose for home.

  • It is recommended to record home after final tool or payload setup.

  • Use move_home later to automatically return to this pose.

  • Keep the home pose consistent across teaching sessions for reproducibility.