ifm / ifm3d-ros

ifm pmd-based 3D ToF Camera ROS Package
Apache License 2.0
40 stars 40 forks source link

How to change PointCloud axis in RViZ #49

Closed dharapatel1596 closed 2 years ago

dharapatel1596 commented 2 years ago

Hello,

I have been using IFM3D305 camera since last week. It works without any problems. Now I have in rviz a robot and it should move around with the help of pointcloud data coming from ifm. My problem is I am seeing the pointcloud inverted and I want to change the direction of it by 90degree rotated and aligned to the grid. My system is : Ubuntu 18.04 ROS Melodic. The pictures below help to understand my problem:

rviz1

rviz2

Any guidance will be appreciated. Thanks in advance :)

lola-masson commented 2 years ago

You can set the extrinsic calibration parameters, either using the Config service in ROS, or using the ifm3d config command with the CLI. The parameters below are the ones to set. Note that the rotation values are in radians.

      "ExtrinsicCalibRotX": "0",
      "ExtrinsicCalibRotY": "0",
      "ExtrinsicCalibRotZ": "0",
      "ExtrinsicCalibTransX": "0",
      "ExtrinsicCalibTransY": "0",
      "ExtrinsicCalibTransZ": "0",
dharapatel1596 commented 2 years ago

That works!!! many Thanks. P.s. : But for me rotation values are in degrees.

lola-masson commented 2 years ago

Thanks for the correction @dharapatel1596. I confused this with another device. Glad this works.