Ask Your Question
0

How to use IR range finder with navigation stack? [closed]

asked 2013-02-23 01:17:23 -0500

How do you use an IR range finder with the navigation stack? I got my eddiebot-like robot all set up, and added the range finders to costmap_common_params.yaml, but it just tells me:

[FATAL] [1361591285.796743183]: Only topics that use point clouds or laser scans are currently supported

So I'm thinking it wouldn't be too translate my range finders into laser scan messages, but that seems like a kludge. It seems like this must have been done before (for example on Eddiebot. What have others done?

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by Procópio
close date 2016-04-27 04:11:19.672496

2 Answers

Sort by » oldest newest most voted
1

answered 2013-02-28 22:53:12 -0500

fergs gravatar image

With the current navigation stack, you have to either convert to PointCloud, PointCloud2, or LaserScan (I would avoid PointCloud as that message might go away some day and is superceded by PointCloud).

The sensor_msgs/Range message is actually fairly new, and while you could certainly go add that capability to the navigation stack, you would have to edit the costmap_2d, possibly AMCL, etc, and so it is more straightforward to just write a node that creates a laserscan out of your sensor data.

Note however, that you may actually want to interpolate in between your range finders or tune the costmap grid size, otherwise you may have serious issues clearing the costmap if you don't have enough other sensors on the robot.

edit flag offensive delete link more

Comments

Thanks, I changed my code to output a Range message along with an equivalent LaserScan message. I do also have a Kinect, these are just to sense the things that are too close for the Kinect to see.

Jon Stephan gravatar image Jon Stephan  ( 2013-03-01 11:15:28 -0500 )edit
0

answered 2013-02-24 00:02:41 -0500

cagatay gravatar image

updated 2013-02-24 06:39:55 -0500

Hello,

However these usually require a LaserScan Msg. However no open documentation exists (as of writing) for use of these packages without a laser, while it is very possible to do SLAM with other sensors.

it is basicly consisting of steps listed below:

  • Converting sensor readings to a 2D plane
  • Converting the 2D plane to a point cloud
  • Converting the point cloud to a laserscan (with pointcloud_to_laserscan)

please check out this for detailed documentation, sensor used in this documentation is a sonar

edit flag offensive delete link more

Comments

Ok, I've written the node to make a LaserScan message from a IR RangeFinder. I don't think you need all those steps, I've just constructed a fake laser scan from the range data.

Jon Stephan gravatar image Jon Stephan  ( 2013-02-24 08:53:48 -0500 )edit

I would most definitely not convert to a point cloud and then use pointcloud_to_laserscan -- that is very inefficient. Just go directly to laser scan. (We don't even use pointcloud_to_laserscan on the Turtlebot anymore, it got replaced with a more direct/optimized depth_image_to_laserscan node).

fergs gravatar image fergs  ( 2013-02-28 22:46:12 -0500 )edit

can you show me your code of node laser scan please? i want to convert range sonor to scanlaser

Emilien gravatar image Emilien  ( 2016-04-26 02:33:22 -0500 )edit

Question Tools

Stats

Asked: 2013-02-23 01:17:23 -0500

Seen: 1,117 times

Last updated: Feb 28 '13