Ask Your Question

Change Gazebo origin coordinate

asked 2018-12-10 08:23:00 -0600

elgarbe gravatar image

Hi, I need to integrate 2 robots in gazebo. The first one is an IRIS quadcopter with px4 in SITL. It works ok. It provide a topic (through mavros) called /mavros/global_position/local. It is the UTM coordinate of the robot. I have X=465710, Y=5249470 Then I have a second robot, a custom made model and controller and it does not have global coordinate available. But I have a /odom topic that provide position in gazebo coordinates (X=240, Y=100) I can insert both model in the same place using gazebo coordinates.

How can I change gazebo origin to a certain UTM coordinate? I would like to gazebo think that it origin is X=465710, Y=5249470.

The other option is to add a GPS to the second robot, but I think it could be harder.


edit retag flag offensive close merge delete


Do you solve this problem? I also have the same problem, please paste your method if you had worked it out, thanks a lot!

sph gravatar image sph  ( 2021-04-27 01:27:19 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2021-04-27 10:59:44 -0600

elgarbe gravatar image

The initial GPS coordinate was hardcoded on px4 firmware SITL. So I've change some configuration file from PX4 SITL firmware and that solved my problem.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2018-12-10 08:23:00 -0600

Seen: 740 times

Last updated: Apr 27 '21