0
$\begingroup$

Rosanswers logo

actually i want each robot to build two local maps , one which is build by its own laser scan and position while the other map from the laser scan and position achieved by other robot through wifi. now what i think , this require two gmapping algorithm having different laser messages . am i rite? is this a rite approach for global mapping? . i,m doing this for global mapping. if yes , how to modify gmapping algorithem for different laser message and position data.

thankyou


Originally posted by Xittx on ROS Answers with karma: 9 on 2013-02-19

Post score: 0


Original comments

Comment by Xittx on 2013-02-19:
actually i want each robot to build two local maps , one which is build by its own laser scan and position while the other map from the laser scan and position achieved by other robot through wifi. now what i think , this require two gmapping algorithm having different laser messages . am i rite?

Comment by Achim on 2013-02-19:
yes, for that you have to run two gmapping algorithms. The stuff with the frame_ids, that shade explained, is important here, too. The result of the two gmapping algorithms will be two maps, which are not aligned, though...

Comment by Xittx on 2013-02-20:
thanks Achim for the response . can you tell me how to do this i have no idea of this. all i want to make user defined laser message and modify gmapping with this messag.

$\endgroup$

2 Answers 2

0
$\begingroup$

Rosanswers logo

Multiple laser message can be published but u have to make sure that they have different namespace. By default the topic name is for laser scan is "scan". You can prefix it with robot namespace like "/robot0/scan" and "/robot1/scan". Secondly for each laser scan the frame_id should be defined correctly w.r.t to respective robots. Gmapping most probably does not support laser scan from multiple sources so, if you want to build a map with multiple scan either you can write your own mapping algorithm or transform messages from one frame_id to other and then publish scan message on 1 single topic only.

Hope it helps..


Originally posted by ayush_dewan with karma: 1610 on 2013-02-19

This answer was ACCEPTED on the original site

Post score: 1


Original comments

Comment by Xittx on 2013-02-20:
thanks for help shade. can you tell me how to change topic name and modify gmapping for it.

$\endgroup$
0
$\begingroup$

Rosanswers logo

I'm not sure what you try to achieve. Build one single map from two laser scanners? I don't think that gmapping node in ros can handle that (look here for example: http://answers.ros.org/question/28514/multiple-robots-with-slam_gmapping/ ). So you would need to write a new node with a different mapping approach anyway.. in that node you can then register to multiple laser_scan topics, easily. :)

Otherwise, if you just want to use the cpu-power of a different computer to process the laserscans from the robot (which has only a slow cpu, maybe), you can adjust the ROS_MASTER_URI on one of the computers and run only one master. Then the setup is just the normal setup, i.e. remap the laser topic on which the driver of the laserscanner publishes so that gmapping listens to it and so on...

As an alternative to the ROS_MASTER_URI you can try http://www.ros.org/wiki/master_sync_fkie, best in combination with node_manager_fkie (there you only need to press one button to enable the sync).


Originally posted by Achim with karma: 390 on 2013-02-19

This answer was NOT ACCEPTED on the original site

Post score: 2

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.