ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Simulating range sensors in Stage and publishing to ROS

asked 2016-08-31 08:51:12 -0600

spmaniato gravatar image

updated 2016-09-02 12:55:48 -0600

According to the Stage Manual ( http://rtv.github.io/Stage/group__mod... ), the generic ranger model that was introduced in Stage 4 should be able to simulate both laser rangefinders and (sonar or IR) range sensors. However, it doesn't look like stage_ros can handle range sensors. I'm inferring that based on the topics published by the stage_ros node and the fact that it doesn't include sensor_msgs/Range.

Is it just a missing feature that I could implement or am I misunderstanding the ranger model?

References:

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2016-09-03 20:13:57 -0600

Shay gravatar image

updated 2016-09-04 21:35:50 -0600

Usually, the sonar message is sensor_msgs/PointCloud or sensor_msgs/PointCloud2, and laser message is sensor_msgs/LaserScan or sensor_msgs/PointCloud.

sensor_msgs/Range just contains a single range, so I think it is not used widely.


EDIT

I used the pioneer robot simulator Mobilesim, which is derived from stage. And there is a ros node rosaria which get info from Mobilesim and publish sensor_msgs/PointCloud and sensor_msgs/PointCloud2 for 16 sonar sensors on the pioneer robot.

Maybe you can refer to this.

edit flag offensive delete link more

Comments

According to the ROS API documentation, a sonar or IR sensor measurement falls under the Range message use cases: http://docs.ros.org/api/sensor_msgs/h... Other simulators, such as STDR, do publish Range messages: http://wiki.ros.org/stdr_robot?distro...

spmaniato gravatar image spmaniato  ( 2016-09-04 01:00:33 -0600 )edit

I don't see how PointCloud is a good fit for sonar/IR. If it's a single sensor, then the points list will always be a singleton (thus why not use Range).

spmaniato gravatar image spmaniato  ( 2016-09-04 01:02:33 -0600 )edit

If there are multiple sonar/IR sensors, they are probably placed in different parts of the robot (e.g. around the base) Therefore, they can't be associated with a single header.frame_id unless they are transformed to a common frame before publication.

spmaniato gravatar image spmaniato  ( 2016-09-04 01:04:36 -0600 )edit

Regardless, stage_ros doesn't published PointCloud messages either. Only LaserScanhttp://wiki.ros.org/stage_ros#Publish...

spmaniato gravatar image spmaniato  ( 2016-09-04 01:07:54 -0600 )edit

@Shay I saw your edit. Interesting, I'll take a look. Thanks :-)

spmaniato gravatar image spmaniato  ( 2016-09-04 22:46:30 -0600 )edit

Question Tools

2 followers

Stats

Asked: 2016-08-31 08:51:12 -0600

Seen: 1,448 times

Last updated: Sep 04 '16