Robotics StackExchange | Archived questions

Laserscanner look through objects

Hi,

i have also a problem with the laser scanner (libgazeborosgpuray) under gazebo7, which I need for my simulation. Unlike gazebo5 the laser scanner under gazebo6 and 7 looks through the objects in the simulation.

image description

sdf file of the world:

    <?xml version="1.0"?>
    <sdf version="1.6">
      <world name="default">

    <!-- the ground plane -->
      <model name="ground_plane">
        <static>true</static>
        <link name="link">
          <collision name="collision">        
            <geometry>
              <plane>
                <normal>0 0 1</normal>
                <size>1000 1000</size>
          </plane>
        </geometry>
        <surface>
          <friction>
            <ode>
              <mu>100</mu>
              <mu2>50</mu2>
            </ode>
          </friction>
        </surface>
      </collision>
      <visual name="visual">
        <geometry>
          <empty></empty>
        </geometry>
        <plugin name="GroundPlugin" filename="libGroundPlugin.so">  //Create the ground visual in the plugin
      <MapFolder>example</MapFolder>
        </plugin>
      </visual>
    </link>
  </model>


<!-- the sky -->
    <scene>
       <background>0.5 0.8 1.0 1.0</background>
       <sky></sky>
    </scene>    

<!-- the sun -->
    <include>
      <uri>model://sun</uri>
    </include>  

  </world>
</sdf>

I add the robot separately in the world. The importent part sensor part for the robot:

  <!-- hokuyo -->
  <gazebo reference="laser">
    <sensor type="gpu_ray" name="head_hokuyo_sensor">
      <pose>0 0 0 0 0 0</pose>
      <visualize>true</visualize>
      <update_rate>40</update_rate>
      <ray>
        <scan>
          <horizontal>
            <samples>1000</samples>
            <resolution>1</resolution>
            <min_angle>-0.7854</min_angle>
            <max_angle>0.7854</max_angle>
          </horizontal>
        </scan>
        <range>
          <min>0.01</min>
          <max>10.0</max>
          <resolution>0.1</resolution>
        </range>
        <noise>
          <type>gaussian</type>
          <!-- Noise parameters based on published spec for Hokuyo laser
               achieving "+-30mm" accuracy at range < 10m.  A mean of 0.0m and
               stddev of 0.01m will put 99.7% of samples within 0.03m of the true
               reading. -->
          <mean>0.0</mean>
          <stddev>0.01</stddev>
        </noise>
      </ray>
      <plugin name="gazebo_ros_laser" filename="libgazebo_ros_gpu_laser.so">
        <topicName>scan</topicName>
        <frameName>laser</frameName>
      </plugin>
    </sensor>
  </gazebo>

Has someone a solution for this problem?

thank you.

edit: I think that I will wait for the fix (in a few weeks).

Asked by mdingwer on 2016-06-01 18:41:36 UTC

Comments

The sdf you gave cannot be the same one that you have a picture of. There is no robot in the sdf you posted. Please provide the sdf for the robot as well, so we can try to help

Asked by Peter Mitrano on 2016-06-01 18:54:44 UTC

Answers

This is probably due to this issue.

There's an open pull request to fix it.

Asked by chapulina on 2016-06-01 23:45:46 UTC

Comments

Hi, I have the opposite problem, i want the laser to look through certain objets, is there a way to do it on pourposse?

Asked by BattleCroissant on 2018-01-29 03:40:13 UTC

Comments

I'd ask this as a new question. more likely to be answered

Asked by Peter Mitrano on 2018-01-29 21:23:30 UTC