Changing value of nan in urg_node to max distance

asked 2015-05-11 09:08:25 -0500

Naman gravatar image

updated 2015-05-11 12:23:16 -0500

Hi all,

I am using urg_node to get the laser scan from hokuyo laser which gives nan values when there are no obstacles in front of it. I am having some issues in clearing the costmap because once I remove the obstacle from the front of the robot, hokuyo gives nan values as there are no obstacles in front of it (Its a pretty big room) and because of it, obstacles are not cleared. So, I am wondering how can I convert nan values to say, max_distance + 1 so that costmap can be cleared effectively? This tells you how can it be done for hokuyo_node, can someone help me out in the case of urg_node?

Thanks in advance.
Naman Kumar

edit retag flag offensive close merge delete



RE my answer you linked: AFAIK, the urg_node may also provide NaN when there are scan errors, objects too close, too reflective, etc. How do you know which of these NaN values should be used to clear obstacles? Since the hokuyo_node provides NaN and INF, it is easy to sort out which should clear.

jarvisschultz gravatar image jarvisschultz  ( 2015-05-11 12:39:41 -0500 )edit

That makes sense.. I am still wondering if there is a way to do something in urg_node which can be used to clear costmap..something similar to hokuyo_node

Naman gravatar image Naman  ( 2015-05-11 13:39:43 -0500 )edit

did you find an answer to this? hokuyo_node is now outdated

vbs gravatar image vbs  ( 2018-07-26 08:36:57 -0500 )edit