Hand-Eye Calibration

You are currently viewing the documentation for version 1.8.2. To access documentation for other versions, click the "Switch Version" button located in the upper-right corner of the page.

■ To use the latest version, visit the Mech-Mind Download Center to download it.

■ If you're unsure about the version of the product you are using, please contact Mech-Mind Technical Support for assistance.

In this tutorial, you will perform the automatic hand-eye calibration in the eye-to-hand setup.

The hand-eye calibration establishes the transformation relationship between the camera and robot reference frames (that is camera extrinsic parameters). With this relationship, the object pose determined by the vision system can be transformed into that in the robot reference frame, which guides the robot in performing its tasks.

Video Tutorial: Hand-Eye Calibration (Standard Interface Communication)

Preparation before Calibration

In this section, you will modify the robot calibration program, mount the calibration board, adjust camera parameters, and perform pre-calibration configuration.

Modify the Robot Calibration Program (MM_AUTO_CALIB)

Select the Calibration Program

  1. In the TEACH mode, select JOB  SELECT JOB. Move the cursor to MM_AUTO_CALIB in the JOB LIST and press the SELECT key on the teach pendant.

    choose caribrate file 1
    choose caribrate file 2
  2. The interface is as follows after the program file is selected.

    choose caribrate file 3
You have already modified the IP address and port of the IPC in the section Test Standard Interface Communication. Therefore, you just only need to teach the calibration start point in this tutorial.

Teach the Calibration Start Point

In the calibration process, the robot poses sent by the robot to Mech-Vision must be flange poses. Therefore, before this step, you need to switch the tool No. to that (usually 00) of the tool whose ToolOffset values are all 0. The Tool Center Point (TCP) of Tool00 is at the center of the flange.
  1. Move the robot to the start point for calibration. Move the cursor to MOVJ P099 VJ=5, and press the DIRECT OPEN key on the teach pendant.

    calibrate start point 1
  2. Change the value of P099 to the current pose of the robot: Press the SERVO ON READY key on the teach pendant. Press the MODIFY key and then the ENTER key while holding the enable switch on the back. Make sure the value for TOOL is 00.

    calibrate start point 1 1
    calibrate start point 1 2
    calibrate start point 1 3
    calibrate start point 2
  3. Press the DIRECT OPEN key on the teach pendant again to return to JOB CONTENT.

So far, you have successfully modified the calibration program necessary for the automatic calibration process of YASKAWA robots.

Mount the Calibration Board

In the eye-to-hand setup, the calibration board needs to be mounted to the robot flange adapter.

Follow these steps:

  1. Take the calibration board and flange adapter out of the camera delivery package.

  2. Use screws, gaskets, and nuts to fasten the flange adapter to the flange adapter.

  3. Use screws, gaskets, and nuts to secure the calibration board to the flange adapter. The calibration board is parallel to the XY plane at the robot end.

  4. After mounting, move the robot to the starting point for calibration, i.e., the top surface of the lowest workpiece in the workspace and at the center of the camera’s field of view. The robot will move the calibration board upwards during calibration.

Adjust Camera Parameters

  1. Connect to the camera in Mech-Eye Viewer , and select the calib parameter group in the Parameter Group drop-down list.

    viewer parameter group calib
  2. Adjust the 2D parameters to make sure that the 2D image of the calibration board is clear and neither overexposed nor underexposed.

    Normal Overexposed Underexposed

    normal-2d

    overexposure-2d

    underexposure-2d

  3. Adjust 3D parameters to make sure that the obtained point clouds of the circles on the calibration board are complete and have clear contours. It is recommended to set the Surface Smoothing and Outlier Removal parameters of Point Cloud Processing to Normal to reduce point cloud fluctuation.

    Point cloud complete Point cloud incomplete Point cloud incomplete

    normal-3d

    overexposure-3d

    underexposure-3d

Pre-calibration Configuration

  1. In Mech-Vision, click the Camera Calibration (Standard) button on the toolbar to open the Pre-calibration Configuration window.

  2. In the Select how to calibrate window, select the New calibration radio button, and then click the Next button.

    getting start calib how
  3. In the Select calibration task window, select Hand-eye calibration for listed robot from the drop-down list box, and click the Select robot model button.

    getting start calib task
  4. Click the Brand dropdown box, and select “YASKAWA”. Then, at the right panel, select model “YASKAWA_GP8”, click the Select button, and then click the Next button.

    getting start select robot model
  5. In the Select camera setup window, select the Eye to hand radio button, and then click the Next button.

    getting start calib eth
  6. In the Calibration method and robot control window, select Automatic and Standard Interface, and then click the Next button.

    getting start calib auto interface
  7. In the Pre-calibration Configuration window, keep the default value for Protocol. Click the Start interface service button in the Connect the robot area, and the message on this button will change to Waiting for the robot to connect....

    getting start calib communication
    • In this tutorial, the vision system acts as the TCP server. Therefore, the Host IP address parameters should be set to the IP address and port of the IPC. Since the IP address of the IPC is a local IP address, you do not need to set it and the software uses “0.0.0.0” to indicate it.

    • By default, the IPC uses port 50000 to provide the interface service. You can change the port number as required. If you have changed the port number, remember to use the correct port number when you try to establish communication with the vision system on the robot side.

Run the Calibration Program

  1. Move the cursor back to line 0000, turn the mode switch to REPEAT mode, and press SERVO ON READY key on the teach pendant .

    run program 1
    run program 2
  2. To move the robot at a low speed, select UTILITY  SETUP SPECIAL RUN on the teach pendant screen, and change SPEED LIMIT to VALID.

    low speed run 1
    low speed run 2
  3. Press the green START button on the teach pendant. when the start LED is lit, the robot is running the program.

    run program 3
    In case of emergency, press pause oremergency stop immediately.
  4. When, in the Configuration before Calibration window in Mech-Vision, the current status changes to connected and the button “Waiting for the robot to connect” changes to “Disconnect”, click Calibrate. The Calibration (Eye to hand) window will be prompted.

    start calibration1

    If the robot is connected successfully, the Console tab of Mech-Vision Log panel will display a log.

    start calibration2

Calibration Procedure

Connect to a Camera

  1. In the Connect to Camera step, find the camera to connect in the Detected Cameras list, and click the Connect button.

    eth calib auto connect camera
  2. After the camera is connected, click the Capture once or Capture live button.

  3. In the right Image viewer panel, ensure that the captured 2D image and point cloud meet the calibration requirements and click the Next button on the bottom bar.

If the captured image does not meet the calibration requirements, you need to open the Mech-Eye Viewer software to adjust the 2D and 3D exposure parameters and re-capture images.

Mount Calibration Board & Check Intrinsic Parameters

  1. In the Mount calibration board & check intrinsic parameters step, select the calibration board model for the Standard calibration board model parameter according to its model nameplate in the 1 Select calibration board area.

    eth calib auto select calib board
  2. In the 2 Check calibration board position and point cloud quality area, read carefully the requirements on the calibration board position and point cloud quality, and then click the Capture live button. The Capture live button will turn into Stop capturing and detect position.

  3. Control the robot to move the calibration board to the proper position, and ensure that the 2D image and depth map of the calibration board meet the requirements, and then click the Stop capturing and detect position button.

    eth calib auto install calib board
  4. In the 3 Check intrinsic parameters area, click the Check intrinsic parameters button.

  5. Confirm the results of the camera intrinsic parameter check.

    • If the camera intrinsic parameter check passes, click the OK button in the prompted window, and then click the Next button on the bottom bar.

      eth calib auto check intri pass
    • If the intrinsic parameter check fails, adjust the calibration circle detection parameters by drawing aid circles or modifying detection parameters, and then click the Check intrinsic parameters button.

If the camera still cannot pass the intrinsic parameter check after the above operations, the intrinsic parameters of the camera may be problematic and need to be corrected, or contact Mech-Mind Technical Support.

Set Robot Path

  1. In the Set robot path step, set the Height span parameter in the 1 Set height span of calibration poses area.

    eth calib auto set robot path

    The Height span parameter should be set according to the recommended working distance range of the camera and the size of the robot’s working space.

  2. Click the Generate path parameters button, and click the OK button in the prompted window.

    eth calib auto confirm path parameters
    This operation will slightly move the robot and capture images. The whole process may take 10 to 15 seconds. Please ensure that the robot path is safe. In case of emergency, please tap the emergency stop button on the robot teach pendant to stop the robot immediately.
  3. In the prompted Calibration window, click the OK button.

    eth calib auto confirm pose
  4. In the right Scene viewer panel, confirm that waypoints are reasonable and will not collide with obstacles.

    eth calib auto view path
  5. Click the Generate robot path based on path parameters button and then click the Next button on the bottom bar.

Collect Images and Flange Poses

  1. In the Collect images and flange poses step, select the Save images checkbox.

    eth calib auto add image pose
  2. Click the Control robot to auto move along path and capture images button.

  3. Read the safety window carefully and click the OK button.

    getting start security warnning
  4. Wait until the robot finishes moving along the preset path and the camera finishes capturing images on all waypoints. Captured images can be seen in the right Marker Image and Pose List panel during this process.

    • Please stay away from the robot working area to keep safe.

    • Clicking the Stop robot button can exit the calibration process. But the robot will not stop until it finishes the current waypoint. In case of emergency, please tap the emergency stop button on the robot teach pendant to stop the robot immediately (the robot needs to be reconnected after tapping the emergency stop button).

  5. After the automatic image capturing finishes, click OK in the pop-up window.

    getting start auto capture finished
  6. Confirm that the collected calibration data meets the data requirements, and then click the Next button on the bottom bar.

    eth calib auto data requirements

    If the requirements are not met, please manually move the robot (through the teach pendant or Mech-Viz), select the Manually add more images checkbox, and click the Add an image and record flange pose button to add the calibration board image and enter the robot flange pose.

Calculate Extrinsic Parameters

  1. In the Calculate extrinsic parameters step, click the Calculate extrinsic parameters button.

    eth calib auto calculate extri
  2. In the prompted window indicating calibration success, click the OK button.

    eth calib auto confirm calib result
  3. Click the View extrinsic parameter calibration report button. The extrinsic parameter calibration report will be automatically displayed after it is generated.

    eth calib auto extri calib report
    The extrinsic parameter calibration report displays the results of the Euler angle convention check, camera accuracy check, and robot absolute accuracy check.
  4. Confirm the results of the Euler angle convention check, camera accuracy check, and robot absolute accuracy check in the report, and then click the Close button to close the report.

    • If the camera accuracy in the report does not meet the requirements, please follow the recommendation to troubleshoot the camera accuracy errors. If you want to enhance the calibration accuracy, please refer to the section Calibration Result Check and Analysis.

    • To evaluate the robot absolute accuracy and the accuracy of calculated extrinsic parameters, you can click Robot absolute accuracy and repeatability and Extrinsic parameter accuracy in the “Calculate extrinsic parameters” window and use the error analysis tool to perform robot absolute accuracy check and analyze extrinsic parameter error in ETH setup.

  5. Click the Save button on the bottom bar. In the prompted Save Calibration Files dialog box, click the OK button. The camera calibration result will be automatically saved in the “calibration” directory of the project.

    eth calib auto save calib result

Now you have completed the hand-eye calibration in the eye-to-hand setup.

We Value Your Privacy

We use cookies to provide you with the best possible experience on our website. By continuing to use the site, you acknowledge that you agree to the use of cookies. If you decline, a single cookie will be used to ensure you're not tracked or remembered when you visit this website.