eppl-erau-db / amigo_ros2

ROS2 Support for Unitree Go2
MIT License
11 stars 2 forks source link

Transform of Base to Intel Realsense D435i #3

Open thisismoiself opened 4 days ago

thisismoiself commented 4 days ago

Hey, does anyone here happen to know the transform of the Intel Realsense D435i depth camera on top of the head of the Go2 to the base of the robot? Great work!

JCastel358 commented 3 days ago

Hello yeah i can help you. Are you talking about changing the urdf of the robot? Are you planning on putting the realsense on the middle of the robot?

thisismoiself commented 3 days ago

Thanks for the response! I want to leave the camera on the tip of the head of the robot, as depicted in the image in the README. I require the coordinate transform between the depth camera and the base of the robot for a SLAM related project but was not able to find it anywhere. If i overlooked it in the urdf-file i apologize.

JCastel358 commented 10 hours ago

Hello, ok gotcha I understand. so yeah technically the transformations can be found following the urdf of the robot and the realsense, but since we are using ROS2's robot_state_publisher node, it handles all of the coordinate transforms for us. using the following command the transform can be found between any frame:

ros2 run tf2_ros tf2_echo base_link camera_depth_optical_frame

which gives the following:

- Translation: [0.331, 0.018, 0.085]
- Rotation: in Quaternion [-0.500, 0.500, -0.500, 0.500]
- Rotation: in RPY (radian) [-1.571, -0.000, -1.571]
- Rotation: in RPY (degree) [-90.000, -0.000, -90.000]
- Matrix:
  0.000  0.000  1.000  0.331
 -1.000  0.000  0.000  0.018
  0.000 -1.000  0.000  0.085
  0.000  0.000  0.000  1.000

Here is also what our current tf-tree looks like: frames_2024-12-02_11.24.17.pdf