Get individual model's positions and velocities per time step?

asked 2022-06-13 22:51:42 -0500

kgz gravatar image

Hi all.

Im trying to work with gazebo11's message api to programmatically run simulations and be able to extract data per timestep. I have the ability to spawn models and pause/resume the simulation down, but have been struggling with extracting model information.

So far, Ive used the model_info topic to get initial positions and stats, but it doesnt update per time step. For example, if a model is falling from the sky, it will only update on init spawn and when it hits the ground, but not the time steps in between.

Is there some way to create a topic per individual model and be able to pull this info per time step? Or a topic that stores all this info per model and I supply an ID of some kind? Ive not seen any good examples of being able to refer to a particular model and pull info from it in any of the docs and Ive done extensive searching. Note that this is without using ros, with a python wrapper for the message API.

Id appreciate any help.

edit retag flag offensive close merge delete