Ask Your Question

Revision history [back]

Depending on the laser sensor, if a scan does not hit an obstacle, different values can be associated with it: nan, inf, etc... As a consequence, depending on the values on the /scan topic, the costmap may not treat it.

I am not sure how the hokuyo works, but you can try to add this line to your costmap config: inf_is_valid: true which means that the costmap will treat readings containing "inf" as valid, and therefore use it to clean or mark the costmaps.

If it does not help, you can try to filter your scan to remove and/or change values in its output to make sure they are valid numbers and withing min/max range. Check the laser_filters package.