ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Lidar data is reflected 180 degrees.

asked 2022-04-05 06:21:41 -0500

Dr.Modi gravatar image

Hello everyone I use Slamtec S1 lidar in conjunction with Jetson Nano running Ubuntu 18 and ROS2 Eloquent. I'm using the sllidar_ros2 package and everything looks great. But when I added lidar to my urdf file, in rviz2 I see that lidar data is displayed the other way around. I also have ZED 2, with which I get an IMU, it is also added to urdf and thanks to it my robot is moving in the right direction. However, I don't understand what is wrong with lidar, how can I turn it?

Here is a part of the urdf description with lidar, it is located in the front part of the robot, along with ZED2. Unfortunately, I can't attach files yet, but rviz2 shows as if there is a wall in front of my robot's face and a large space behind, although in reality it's the opposite.

  <!-- Robot Lidar -->  
  <link name="laser">
      <origin xyz="0 0 0.0255" rpy="0 0 0" />
        <cylinder radius="0.0225" length="0.051"/>
      <material name="black">
        <color rgba="0 0 0 1" />

  <joint name="lidar_joint" type="fixed">
    <parent link="base_link"/>
    <child link="laser"/>
    <origin xyz="0.4425 0 0.40" rpy="0 0 0" />
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2022-04-05 06:51:29 -0500

Mike Scheutzow gravatar image

You probably have not correctly specified the yaw for the fixed lidar_joint. For a urdf joint, the order of operation is translate then rotate. Try setting yaw to 3.14159 (radians).

edit flag offensive delete link more


Oh, great! It works, thank you very much!

Dr.Modi gravatar image Dr.Modi  ( 2022-04-05 07:07:03 -0500 )edit

Question Tools

1 follower


Asked: 2022-04-05 06:21:41 -0500

Seen: 438 times

Last updated: Apr 05 '22