0
$\begingroup$

Rosanswers logo

Hello to all,

I'm going to need your help and experience in the following topic.

So far, in every single navigation stack tutorial/example that I found, everybody assumes that we have to use the gmapping package to prepare the two require files map.pgm and map.yaml

Then pass this map to a map server and support localisation etc.

In my specific application, it happens to have already the static map which is actually the floor plan of the floor. Therefore, I don't want the robot to build the map and at this stage I need to get this autocad file (which could be exported in a png format) and "convert" it to a ROS map file.

I imagine that I need to pre-proccess it in a way and simplify it that white space is the free space, walls are black lines and gray unknown. Then point to those couple of files (pgm and yaml) map server and continue with localisation and so on.

But what about the scaling? or what about the yaml file and how to populate it? Does anybody has done something similar? Should I do something specific to avoid troubles?

Thanks in advance for your support.

Regards, Angelos


Originally posted by angelos.p on ROS Answers with karma: 148 on 2017-11-03

Post score: 1

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

I imagine that I need to pre-proccess it in a way and simplify it that white space is the free space, walls are black lines and gray unknown. Then point to those couple of files (pgm and yaml) map server and continue with localisation and so on.

You got the idea right. Regarding the question about the yaml, it is quite simple: the origin is up to you, and the resolution is the size in meters of a pixel of your image.

However, beware when using the approach you propose. In a real situation, what the robot "sees" with its sensors is quite different from a perfect map taken from the floor plan. So, even though you'll have a nice map, you may have trouble localizing the robot there due to mismatch of what the robot is expected to "see" and what it is actually "seeing".

An example would be glass walls, which would be in your floor plan but are invisible to a LIDAR.


Originally posted by Procópio with karma: 4402 on 2018-01-05

This answer was ACCEPTED on the original site

Post score: 1

$\endgroup$

Your Answer

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