Gazebo | Ignition | Community
Ask Your Question

Revision history [back]

The problem is <topicName>scan</topicName>. Both lasers publish on the same topic. This creates conflicting information on the laser scans. The glitch you mention probably comes from the localization failing to keep up.

Each laser should publish on its own topic, e.g. scan_front and scan_rear.

The problem is <topicName>scan</topicName>. Both lasers publish on the same topic. This creates conflicting information on the laser scans. The glitch you mention probably comes from the localization failing to keep up.

Each laser should publish on its own topic, e.g. scan_front and scan_rear.

Edit: Actually, no. The frame names should be enough to differentiate them. Not sure what to assume with the given information.

The problem is <topicName>scan</topicName>. Both lasers publish on the same topic. This creates conflicting information on the laser scans. The glitch you mention probably comes from the localization failing to keep up.

Each laser should publish on its own topic, e.g. scan_front and scan_rear.

Edit: Edit:
Actually, no. The frame names should be enough to differentiate them. Not sure what to assume with the given information.

Edit2:
So, I did some experiments. Your problem is probably the sensor names.

  • You are using the same names for the sensors and the plugins. You need to differentiate them. Although gazebo doesn't throw any errors when you set the same sensor name, the output laser scans are wrong.
  • Regarding the publish rate, check the update rate of all the range sensors on your robot. I had problems in the past where I couldn't increase the rate of a range sensor, and it turned out that this was somehow connected to the rate of my laser scanners. (also, in the code you provided, the update rate is 2)