Home | Tutorials | Wiki | Issues
Ask Your Question

Revision history [back]

This tutorial should be useful to you:

Gazebo Tutorials: Model plugins

It explains how to write a plugin in C++ which is loaded with Gazebo and sets the velocity of a model. In your case, you should change SetLinearVel to GetWorldPose to get the position. You can get the time stamp from common::UpdateInfo.

An alternative approach would be to create a program which subscribes to the ~/pose/info topic as explained on the following tutorial:

Gazebo Tutorials: Topic subscription