How to visualize and control Parrot-Sphinx via Gazebo’s topics

Messages in Gazebo are sent on named channels called topics via publishers. On the other side of a topic are subscribers, which receive callbacks when messages arrive.

A list of all the topics in use on a running system can be found with the following command (make sure Gazebo is running first):

gz topic -l

The following command will dump the world statistics to the terminal:

gz topic -e "~/world_stats"

The following command will publish a message on the wind topic, modifying the wind velocity:

gz topic -p "~/wind" -m linear_velocity{x:0\ y:1\ z:0}