Gazebo Read

Receive messages from Gazebo server

  • Library:
  • Robotics System Toolbox / Gazebo Co-Simulation

Description

The Gazebo Read block receives messages from the Gazebo server based on the topic and message type that the block specifies. The block outputs the latest message received as a bus signal, Msg, and a Boolean, IsNew, which indicates whether a message was received during the previous time step.

This block is part of a co-simulation interface between MATLAB® and Gazebo for exchanging data and sending commands. To see a basic example, check Perform Co-Simulation between Simulink and Gazebo

Ports

Output

expand all

Status of the message received, output as a Boolean, which indicates whether the block output Msg was received in the previous time step.

Data Types: Boolean

Gazebo message, output as a bus signal, with elements relevant to the specific Topic and Message type.

The Msg output always outputs the most recent message received.

Data Types: bus

Parameters

expand all

To get a topic from an existing Gazebo simulation, select From Gazebo. Click the Select button to see a list of available topics. To connect to a Gazebo simulation, click Configure Gazebo network and simulation settings in the block mask.

To enter a custom topic without an active Gazebo connection, select Specify your own. Use the Topic parameter to type the name of the message.

Topic name of message, specified as a string.

To get a topic from an existing Gazebo simulation, select From Gazebo. Click the Select button to see a list of available topics. To connect to a Gazebo simulation, click Configure Gazebo network and simulation settings in the block mask.

To specify a topic without connecting, select Specify your own.

Click Select to get a list of message types available in Gazebo. If you choose your Topic from a connected Gazebo simulation, this parameter is set automatically.

Sample time indicates when, during simulation, the block produces outputs and if appropriate, updates its internal state.

Extended Capabilities

C/C++ Code Generation
Generate C and C++ code using Simulink® Coder™.

Introduced in R2019b