Ground plain is not visible, while using block_laser GAZEBO plugin [closed]

asked 2012-11-08 04:54:09 -0500

dmeltz gravatar image

updated 2012-11-24 00:53:45 -0500

Hello all.

I trying to include in my car simulation a velodyn sensor. For this purpose i added to my car URDF model the "libgazebo_ros_block_laser.so" plugin :

  <joint name="BLOCK_LIDAR_joint" type="fixed">
    <origin rpy="0 0 0" xyz="0.5 0 0.5"/>
    <parent link="base_link"/>
    <child link="BLOCK_LIDAR_link"/>
  </joint>
  <link name="BLOCK_LIDAR_link">
    <inertial>
      <mass value="0.01"/>
      <origin xyz="0 0 0"/>
      <inertia ixx="0.001" ixy="0.0" ixz="0.0" iyy="0.001" iyz="0.0" izz="0.001"/>
    </inertial>
    <visual>
      <origin rpy="0 0 0" xyz="0 0 0"/>
      <geometry>
        <box size="0.1 0.1 0.1"/>
      </geometry>
      <material name="green"/>    
    </visual>
    <collision>
      <origin rpy="0 0 0" xyz="0 0 0"/>
      <geometry>
        <box size="0.01 0.01 0.01"/>
      </geometry>
    </collision>
  </link>

 <gazebo reference="BLOCK_LIDAR_link">
    <sensor:ray name="dany_car_BLOCK_LIDAR_sensor">
          <rayCount>180</rayCount>
          <rangeCount>180</rangeCount>
          <laserCount>1</laserCount>

          <origin>0.0 0.0 0.0</origin>
          <displayRays>false</displayRays>

          <minAngle>-90</minAngle>    
          <maxAngle> 90</maxAngle>

          <minRange>0.05</minRange>
          <maxRange>100.0</maxRange>
          <updateRate>10.0</updateRate>

          <verticalRayCount>64</verticalRayCount>
          <verticalRangeCount>64</verticalRangeCount>
          <verticalMinAngle>-26.8</verticalMinAngle>
          <verticalMaxAngle>2</verticalMaxAngle>

          <controller:gazebo_ros_block_laser name="dany_car_LIDAR_BLOCK_controller" plugin="libgazebo_ros_block_laser.so">
            <gaussianNoise>0.005</gaussianNoise>
            <alwaysOn>true</alwaysOn>
            <updateRate>10.0</updateRate>
            <topicName>/dany_car_sensors/block_lidar/full_cloud</topicName>
            <frameName>BLOCK_LIDAR_link</frameName>
            <interface:laser name="dany_car_BLOCK_LIDAR_iface" />
          </controller:gazebo_ros_block_laser>
        </sensor:ray>
       <turnGravityOff>true</turnGravityOff>
        <material>Gazebo/Green</material>
    </gazebo>

Everything seems to work fine, the URDF model is spawned in GAZEBO with no errors and the point cloud topic is advertise.

But still when i visualize the PointCloud in Rviz it's missing the points that belong to the ground plain. Instead i get weird points that appears beneath the ground plain directly beneath the existing objects.

Beneath are print-screens of GAZEBO and RVIZ. the little blue rectangle in the middle is my car robot, the LIDAR sensor is directed to the left (towards the big blue wall).

GAZEBO :

image description

RVIZ :

image description

the red points are actually not existing and has negative Z values

Maybe someone can help me with that, thanks.

edit retag flag offensive reopen merge delete

Closed for the following reason Gazebo Question: The Gazebo community prefers to answer questions at: http://answers.gazebosim.org by tfoote
close date 2015-06-29 02:18:16.692310