Question. Do you know that the character "?" means I'm asking a question? Question. Do you know that spoken inflection also provides the same cue? So please don't say, "Question" before you ask your question. Believe me I'll know.


You may have heard of the [ Web Workers API
](https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API) . The API
is different from ` worker_threads ` because the needs and technical
conditions are different, but they can solve similar problems in the browser
runtime.


static VOID STDMETHODCALLTYPE LoadImageNotify(IN PUNICODE_STRING
FullImageName, IN HANDLE ProcessId, IN PIMAGE_INFO ImageInfo)


[ ![](https://blog.logrocket.com/wp-
content/uploads/2022/04/linkedin.jpg?w=150&h=150&crop=1)
](https://blog.logrocket.com/author/chibuikenwachukwu/) [ Chibuike Nwachukwu
](https://blog.logrocket.com/author/chibuikenwachukwu/)


[ July 25, 2019 at 7:15 am  ](https://blog.logrocket.com/multithreading-node-
js-worker-threads/#comment-228)


Tracing messages showing multiple threads calling into LoadImageNotify() with
_different_ ProcessId parameter values is quite normal. However, there is a
particular runtime environment over which I have no control where I see
LoadImageNotify() invoked simultaneously by 2 different threads for the same
ProcessId value as described above. That runtime environment affects several
hundred computers where the driver is deployed and the bugcheck happens
consistently in a repeatable manner on any/all of those computers.


[ ![](https://blog.logrocket.com/wp-content/uploads/2021/07/Ibiyemi-
Adewakun.png?w=150&h=150&crop=1)
](https://blog.logrocket.com/author/ibiyemiadewakun/) [ Ibiyemi Adewakun
](https://blog.logrocket.com/author/ibiyemiadewakun/)


The ` Resizing image ` message may not be the best way to relay such
information, but its purpose is to always run while the image processes — that
is, while the worker thread is running.


Running heavy scripts from the main thread can cause UX issues on your site,
which isn’t ideal. However, running a script apart from the main thread can
create issues, as we directly don’t have access to the main thread APIs like `
window ` , ` document ` , or ` localStorage ` .


We can also send partial results. Imagine that you are processing thousands of
images. Maybe you want to send a message per image processed, but you don’t
want to wait until all of them are processed.


  * Efficiently utilizes all available CPU cores
  * Enhances load balancing by distributing incoming connections among multiple worker processes
  * Simplifies the handling of incoming requests by providing a shared server port


Worker threads operate in isolated contexts, exchanging information with the
main process using message passing. This approach helps us avoid the race
conditions problem regular threads have. At the same time, worker threads live
in the same parent process as the main thread, so they use a lot less memory.


      sharp(imagePath)
        .resize(width, height)
        .toFile(outputPath, (err) => {
          if (err) {
            throw err;
          }
          // Send a message back to the main thread
          parentPort.postMessage("Image resized successfully!");
        });
    }


Maybe this database query takes a minute, but the ` Running query ` message
will be shown immediately after invoking the query. Additionally, we will see
the ` Hey there ` message a second after invoking the query regardless of
whether the query is still running or not.


[ May 27, 2020 at 7:45 pm  ](https://blog.logrocket.com/multithreading-node-
js-worker-threads/#comment-2625)


Here’s where [ Partytown ](https://github.com/BuilderIO/partytown) comes in.
Partytown is a lazy-loaded, 6kB package that helps you solve the issue
mentioned. Your third-party packages will run as expected without affecting
the main thread.


Now, we can process 10 items each time the event loop runs and call `
setImmediate(callback) ` so that if there’s something else the program needs
to do, it will do it in between those chunks of 10 items. I’ve added a `
setInterval() ` to demonstrate exactly that.


Dejan.


[ about ](/about/) |  [ faq ](/faq/) |  [ help ](/help/ "help") |  [ privacy
policy ](/privacy/) |  [ terms of service ](/terms/)


8. ![](https://secure.gravatar.com/avatar/47d49df3b4971c1f94bef21411909e5a?s=36&d=mm&r=g) **ajay sharma** says:


What is of concern is that this driver has been working just fine, as-is,
until recently and only has the bugcheck occurring in a specific runtime
environment. I suspect that there is some negative interaction between two or
more security enhancement products being present and functional at the same
time such that a newly created process is being subjected to DLL injection or
some other code injection that results in additional threads being created and
DLLs loaded in a way that is causing the simultaneous delivery of image load
events. The lack of locking in the callback functions then leads to the
double-remove and subsequent bugcheck. Also of note, it has not been possible,
yet, to reproduce the crash in a controlled development lab environment, but
that is likely due to not having sufficiently duplicated the runtime
environment in a virtual machine. In the environment where the failure
happens, though, it is easily repeatable and the complete memory dump that is
produced always shows the same underlying double-remove as the cause for the
bugcheck.


      * [ Beta 2 ( ` r2b2  ` ) ](../Releases/Beta2-Overview.html)
      * [ Beta 1 ( ` Asphalt  ` ) ](../Releases/Beta1-Overview.html)
      * [ Alphas ](../Releases/Alpha-Overview.html)
    * [ Development process for a release ](../Releases/Release-Process.html)
  * [ Tutorials ](../Tutorials.html)
    * [ Beginner: CLI tools ](../Tutorials/Beginner-CLI-Tools.html)
      * [ Configuring environment ](../Tutorials/Beginner-CLI-Tools/Configuring-ROS2-Environment.html)
      * [ Using ` turtlesim  ` , ` ros2  ` , and ` rqt  ` ](../Tutorials/Beginner-CLI-Tools/Introducing-Turtlesim/Introducing-Turtlesim.html)
      * [ Understanding nodes ](../Tutorials/Beginner-CLI-Tools/Understanding-ROS2-Nodes/Understanding-ROS2-Nodes.html)
      * [ Understanding topics ](../Tutorials/Beginner-CLI-Tools/Understanding-ROS2-Topics/Understanding-ROS2-Topics.html)
      * [ Understanding services ](../Tutorials/Beginner-CLI-Tools/Understanding-ROS2-Services/Understanding-ROS2-Services.html)
      * [ Understanding parameters ](../Tutorials/Beginner-CLI-Tools/Understanding-ROS2-Parameters/Understanding-ROS2-Parameters.html)
      * [ Understanding actions ](../Tutorials/Beginner-CLI-Tools/Understanding-ROS2-Actions/Understanding-ROS2-Actions.html)
      * [ Using ` rqt_console  ` to view logs ](../Tutorials/Beginner-CLI-Tools/Using-Rqt-Console/Using-Rqt-Console.html)
      * [ Launching nodes ](../Tutorials/Beginner-CLI-Tools/Launching-Multiple-Nodes/Launching-Multiple-Nodes.html)
      * [ Recording and playing back data ](../Tutorials/Beginner-CLI-Tools/Recording-And-Playing-Back-Data/Recording-And-Playing-Back-Data.html)
    * [ Beginner: Client libraries ](../Tutorials/Beginner-Client-Libraries.html)
      * [ Using ` colcon  ` to build packages ](../Tutorials/Beginner-Client-Libraries/Colcon-Tutorial.html)
      * [ Creating a workspace ](../Tutorials/Beginner-Client-Libraries/Creating-A-Workspace/Creating-A-Workspace.html)
      * [ Creating a package ](../Tutorials/Beginner-Client-Libraries/Creating-Your-First-ROS2-Package.html)
      * [ Writing a simple publisher and subscriber (C++) ](../Tutorials/Beginner-Client-Libraries/Writing-A-Simple-Cpp-Publisher-And-Subscriber.html)
      * [ Writing a simple publisher and subscriber (Python) ](../Tutorials/Beginner-Client-Libraries/Writing-A-Simple-Py-Publisher-And-Subscriber.html)
      * [ Writing a simple service and client (C++) ](../Tutorials/Beginner-Client-Libraries/Writing-A-Simple-Cpp-Service-And-Client.html)
      * [ Writing a simple service and client (Python) ](../Tutorials/Beginner-Client-Libraries/Writing-A-Simple-Py-Service-And-Client.html)
      * [ Creating custom msg and srv files ](../Tutorials/Beginner-Client-Libraries/Custom-ROS2-Interfaces.html)
      * [ Implementing custom interfaces ](../Tutorials/Beginner-Client-Libraries/Single-Package-Define-And-Use-Interface.html)
      * [ Using parameters in a class (C++) ](../Tutorials/Beginner-Client-Libraries/Using-Parameters-In-A-Class-CPP.html)
      * [ Using parameters in a class (Python) ](../Tutorials/Beginner-Client-Libraries/Using-Parameters-In-A-Class-Python.html)
      * [ Using ` ros2doctor  ` to identify issues ](../Tutorials/Beginner-Client-Libraries/Getting-Started-With-Ros2doctor.html)
      * [ Creating and using plugins (C++) ](../Tutorials/Beginner-Client-Libraries/Pluginlib.html)
    * [ Intermediate ](../Tutorials/Intermediate.html)
      * [ Managing Dependencies with rosdep ](../Tutorials/Intermediate/Rosdep.html)
      * [ Creating an action ](../Tutorials/Intermediate/Creating-an-Action.html)
      * [ Writing an action server and client (C++) ](../Tutorials/Intermediate/Writing-an-Action-Server-Client/Cpp.html)
      * [ Writing an action server and client (Python) ](../Tutorials/Intermediate/Writing-an-Action-Server-Client/Py.html)
      * [ Composing multiple nodes in a single process ](../Tutorials/Intermediate/Composition.html)
      * [ Launch ](../Tutorials/Intermediate/Launch/Launch-Main.html)
        * [ Creating a launch file ](../Tutorials/Intermediate/Launch/Creating-Launch-Files.html)
        * [ Integrating launch files into ROS 2 packages ](../Tutorials/Intermediate/Launch/Launch-system.html)
        * [ Using substitutions ](../Tutorials/Intermediate/Launch/Using-Substitutions.html)


Node.js won’t evaluate the next code block in the event queue until the
previous one has finished executing.


[ ![](https://blog.logrocket.com/wp-
content/uploads/2022/01/unnamed-1.jpg?w=150&h=150&crop=1)
](https://blog.logrocket.com/author/peteraideloje/) [ Peter Aideloje
](https://blog.logrocket.com/author/peteraideloje/)


  *[
              2019-03-30 04:49:03 -0600
             ]: 2019-03-30 04:49:03 -0600
  *[
             2019-03-30 04:51:46 -0600
            ]: 2019-03-30 04:51:46 -0600
  *[
              2019-03-30 05:12:39 -0600
             ]: 2019-03-30 05:12:39 -0600
  *[
              2019-03-30 05:44:34 -0600
             ]: 2019-03-30 05:44:34 -0600
  *[
        2019-03-30 04:49:03 -0600
       ]: 2019-03-30 04:49:03 -0600
  *[
        2024-04-14 12:57:56 -0600
       ]: 2024-04-14 12:57:56 -0600


Phenix's AvatarJoin Date
Sep 2002
Location
Near A Cube
Posts
228
Re: Multithreading, Callbacks and Synchronization
azteched
...the answer to your question is no. Callbacks have nothing inherently to do with multithreading; the functions will be called synchronously.


Reply


Contact Us VB Forums Top


###  Leave a Reply  [ Cancel reply ](/multithreading-node-js-worker-
threads/#respond)


Yarp Based Plugins for Gazebo Simulator
Enrico Mingo Hoffman, Istituto Italiano di Tecnologia, enrico.mingo@iit.it, Genova, Italy
Silvio Traversaro, Istituto Italiano di Tecnologia, silvio.traversaro@iit.it, Genova, Italy
Alessio Rocchi, Istituto Italiano di Tecnologia, alessio.rocchi@iit.it, Genova, Italy
Mirko Ferrati, Centro di Ricerca “E. Piaggio”, mirko.ferrati@centropiaggio.unipi.it, Pisa, Italy
Alessandro Settimi, Centro di Ricerca “E. Piaggio”, alessandro.settimi@centropiaggio.unipi.it, Pisa, Italy
Francesco Romano, Istituto Italiano di Tecnologia, francesco.romano@iit.it, Genova, Italy
Lorenzo Natale, Istituto Italiano di Tecnologia, lorenzo.natale@iit.it, Genova, Italy
Antonio Bicchi, Centro di Ricerca “E. Piaggio”, antonio.bicchi@centropiaggio.unipi.it, Pisa, Italy
Francesco Nori, Istituto Italiano di Tecnologia, francesco.nori@iit.it, Genova, Italy
Nikos G. Tsagarakis, Istituto Italiano di Tecnologia, nikos.tsagarakis@iit.it, Genova, Italy
The research leading to these results has received funding from the European Union Seventh Framework
Programme [FP7-ICT-2013-10] under grant agreements n.611832 WALKMAN, ERC Advanced Grant no. 291166
SoftHands and the CoDyCo project (FP7-ICT-2011-9, No. 600716).
Abstract
This paper presents a set of plugins for the Gazebo simulator that enables the interoperability between a
robot, controlled using the YARP framework, and Gazebo itself. Gazebo is an open-source simulator that can
handle different Dynamic Engines (ODE, DART, Bullet, SimBody), backed up by the Open Source Robotics
Foundation (OSRF) and supported by a very large community. Since our plugins conform with the YARP layer
used on the real robot, applications written for our robots, COMAN and iCub, can be run on the simulator
with no changes. Our plugins have two main components: a YARP interface with the same API as the real
robot interface, and a Gazebo plugin which handles simulated joints, encoders, IMUs, force/torque sensors and
synchronization. The robot model is provided to the simulator by means of an SDF file, which describes all
the geometric, dynamic and visual characteristics of a robot. Once the SDF is read from Gazebo, our plugins
are loaded and associated with the simulated robot model and the simulated world. Different modules for
COMAN and iCub have been developed using Gazebo and our plugins as a testbed: joint impedance control plus
gravity compensation, dual arm Cartesian control for manipulation tasks, dynamic walking, etc. This work has
been developed as part of a joint effort between three different European Projects “WALKMAN”, “CoDyCo”
and “SoftHands” aiming at implementing a common simulation platform to develop and test algorithms for
our robotic platforms. This work is available as open-source to all the researchers in the YARP community
(https://github.com/robotology/gazebo_yarp_plugins).
Keywords: Simulator, Robotics, YARP, Gazebo, Open-Source
1 Introduction
In the past years, robotics researchers have been developing many robotics frameworks such as OpenRDK
(Calisi et al. [2008]), YARP (Metta et al. [2006]) or
ROS (Quigley et al. [2009]) in order to ease the creation of generic applications for robots and encourage
code reuse. The performance overhead introduced by
these frameworks is balanced by the architectural benefits, for example they allow to build modular systems
to execute one or more assigned tasks.
In these frameworks, the simulator is a module that


##  Part 1: See the sensor in action


target application.
Webots (Michel [2004]) is a development environment
used to model, program and simulate mobile robots.
With Webots the user can design complex robotic
setups, with one or several, similar or different robots,
in a shared environment. A large choice of simulated
sensors and actuators is available. The robot controllers can be programmed with the built-in IDE or
with third party development environments. The robot
behavior can be tested in dynamic simulated worlds
(ODE based). The controller programs can optionally
be transferred to commercially available real robots.
V-REP (Rohmer et al. [2013]), similarly to Webots,
embeds different tools that permit fast developing of
algorithms, the code can be transferred inside real
robotic hardware.
Gazebo (Koenig and Howard [2004]) is a multi-robot
simulator for outdoor environments. As Stage (part of
the Player project, Gerkey et al. [2003]), it is capable
of simulating a population of robots, sensors and objects. It generates both realistic sensor feedback and
physically consistent interactions between objects. It
includes an accurate simulation of rigid-body physics
and allows the user to select between multiple dynamics engines (ODE, Bullet, SimBody Sherman et al.
[2011] and DART Tech [2013]). Gazebo has been used
to compare algorithms for navigation and grasping in
a controlled environment.
Finally, two notable softwares are the OpenHRP
project used in Japan for the HRP series (Kanehiro
et al. [2004]) and MuJoCo (Todorov et al. [2012]) used
for model-based control.
Our decision to add a YARP interface to Gazebo is
motivated by the following considerations. We want
to switch between fast, not accurate simulations and
slow, accurate ones, thus we need the capability of
choosing among different dynamic engines. We also
want a simulator which is both easy to use and to
expand in order to add new robot models. Finally,
we prefer an open-source software with an active
community and money investments. Gazebo fulfills our
requirements, in particular it is expandable with a
plugin structure: in this work our YARP interface is a


This is the direction of the measurement. Try changing the example above to `
parent_to_child ` . After being toppled the sensor reports a force of -98 N on
the Y axis and a torque of +147 Nm about the X axis. This is the same
magnitude as before but opposite direction.


In a new terminal open the topic viewer with the following command:


We want to apply force to a specific link in the ` Simple Arm ` model. On the
World tree, right-click ` arm_wrist_lift ` and choose ` Apply Force/Torque ` .
A dialog will pop up and you'll see a straight arrow and a curved arrow attach
to the arm.


All sensors have a common set of parameters in the [ SDF sensor schema
](http://sdformat.org/spec?ver=1.6&elem=sensor) .


3.3.2 6-axis Force/Torque sensor
A Force/Torque sensor measures a wrench in the robot
structure (Figure 3). The sensor, at the time of writing,
is simulated in Gazebo as if it was attached to the
reference frame associated to a joint. On the YARP
side, the reading of a generic sensor is implemented
as a IAnalogSensor interface (Figure 5). The broadcasted data is a vector of six numbers representing the
forces and the torques applied on that reference frame.
3.3.3 IMU sensor
An IMU measures velocity, orientation, and gravitational forces, using a combination of accelerometers
and gyroscopes, of the link where it is placed. It is also
possible to add white Gaussian noise on the measurement (Figure 7). Similar to the Force/Torque sensor,
it is implemented as a IAnalogSensor interface.
Figure 5: The Force/Torque sensor in the left arm is
implemented as a YARP IAnalogSensor interface. At
every step the internal state of the plugin is updated
with the last readings of forces and torques from the
simulation.
3.3.4 Clock
A fundamental aspect in simulations is the synchronization between YARP modules and the simulated
robot. A YARP module is a process in which one
or more threads are started. When such modules are
used in the real robot, the thread rate is timed by
the machine (system) clock, also called the wall clock.
When the simulation is running we want the rate of
such modules to be synchronized with the simulated
time, otherwise the control loop could run faster or
slower with respect to the simulated robot dynamics.
The real-time factor (RTF) of the simulation is given
by
RT F = update frequency × step time (2)
and is kept to one when the desired update frequency
is the inverse of the time increased at each step in the
0 10 20 30 40 50 60 70 80 90 100 110 120 130 140 150 160
0.5
1
1.5
2
2.5
3


[ edit ](/s/answers/300191/edit/) flag offensive  delete  [ link
](/question/243173/interpretation-of-forcetorque-sensor-using-
gazebo_ros_ft_sensor-plugin/?answer=300191#post-id-300191 "permanent link")
more


[ about ](/about/) |  [ faq ](/faq/) |  [ help ](/help/ "help") |  [ privacy
policy ](/privacy/) |  [ terms of service ](/terms/)


###  Adding a force/torque sensor to a link


[ edit ](/questions/243173/edit/) [ retag ](/s/questions/243173/retag/) flag
offensive  [ close ](/questions/243173/close/) merge  delete


Last updated: **Sep 06 '16**


Regardless of this setting, the torque component is always expressed about the
origin of the joint frame.


©2014 Open Source Robotics Foundation


##  Apply force to a link


#  The interface explained


###  Generic parameters


##  Part 2: Explanation of the above steps


Sort by »  [ oldest  ](/question/243173/interpretation-of-forcetorque-sensor-
using-gazebo_ros_ft_sensor-plugin/?sort=oldest#sort-top) [ newest
](/question/243173/interpretation-of-forcetorque-sensor-using-
gazebo_ros_ft_sensor-plugin/?sort=latest#sort-top) [ most voted
](/question/243173/interpretation-of-forcetorque-sensor-using-
gazebo_ros_ft_sensor-plugin/?sort=votes#sort-top)


This world has one link and one joint. The link is a sphere with a mass of 10
kg offset 1.5 m from the joint. The joint connects the sphere to the world,
allowing rotation on its X axis. At the start the sphere is balanced above the
joint. There is no torque on the joint. The force on the joint comes from
gravity.


Source Installation on Ubuntu
These instructions apply to Ubuntu Jammy (22.04) and Ubuntu 24.04.
Install tools
The use of some additional tools is recommended to help with the source compilation, although other ways of correctly getting and building the sources are also possible.
The easiest way to get the sources of all libraries is to use vcstool.
To compile all the different libraries and gz-sim in the right order colcon is recommended. The colcon tool is available on all platforms using pip (or pip3, if pip fails).
Some tools require Python 3.5 (or higher) which is not the default option on some platforms (like Ubuntu Focal). The Python virtualenv could be a useful solution in cases where the default option cannot be easily changed.
Generic tools
Install tools needed by this tutorial:
sudo apt install python3-pip wget lsb-release gnupg curl
vcstool and colcon from pip
PIP is available on all platforms:
pip install vcstool || pip3 install vcstool
pip install -U colcon-common-extensions || pip3 install -U colcon-common-extensions
Check that no errors were printed while installing with PIP. If your system is not recognising the commands, and you're using a system that is compatible with Debian or Ubuntu packages, see the instructions below to install using apt.
After installing vcstool and colcon with PIP, you may need to add their executables to your $PATH. Check where the installation of these packages took place:
pip show vcstool || pip3 show vcstool | grep Location
pip show colcon-common-extensions || pip3 show colcon-common-extensions | grep Location
If your install path is prefixed with $HOME/.local, you'll probably need to add the executables within this directory to your $PATH in order to avoid "command not found" errors when using vcstool and colcon later on:
export PATH=$PATH:$HOME/.local/bin/
vcstool and colcon from apt
An alternative method is to use the .deb packages available on Debian or Ubuntu:
sudo sh -c 'echo "deb http://packages.ros.org/ros2/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros2-latest.list'
curl -s https://raw.githubusercontent.com/ros/rosdistro/master/ros.asc | sudo apt-key add -
sudo apt-get update
sudo apt-get install python3-vcstool python3-colcon-common-extensions
Git
Gazebo libraries use git for version control, so it must be available in the system for vcstool to work properly.
sudo apt-get install git
Getting the sources
The instructions below use some UNIX commands to manage directories but the equivalent alternatives on Windows should provide the same result.
The first step is to create a developer workspace in which vcstool and colcon can work:
mkdir -p ~/workspace/src
cd ~/workspace/src
All the sources of gazebo-harmonic are declared in a yaml file. Download it to the workspace:
wget https://raw.githubusercontent.com/gazebo-tooling/gazebodistro/master/collection-harmonic.yaml
Use vcstool to automatically retrieve all the Gazebo libraries sources from their repositories:
vcs import < collection-harmonic.yaml
The src subdirectory should contain all the sources ready to be built.
Install dependencies
Before compiling it is necessary to install all the dependencies of the different packages that compose the Harmonic collection. Every platform has a different method to install software dependencies.
Add packages.osrfoundation.org to the apt sources list:
sudo wget https://packages.osrfoundation.org/gazebo.gpg -O /usr/share/keyrings/pkgs-osrf-archive-keyring.gpg
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/pkgs-osrf-archive-keyring.gpg] http://packages.osrfoundation.org/gazebo/ubuntu-stable $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/gazebo-stable.list > /dev/null
sudo apt-get update
The command below must be run from a workspace with the Gazebo source code and will install all dependencies in Ubuntu:
cd ~/workspace/src
sudo apt -y install \


[ ![Google+](/assets/google_gray-
cc34826f560f99c7a9b7db88cd5f2db4d28fd4b3afcfa4b897435c51e3b25518.png)
](//plus.google.com/u/0/115981436296571800301?prsrc=3) [
![YouTube](/assets/youtube_gray-978838444154eb6aa5e4aa38489f66d10e40361dd06a3814411c211cba013752.png)
](https://www.youtube.com/channel/UCJyqf9XJpDoM9XnpAwW6WxA) [
![YouTube](/assets/twitter_gray-8e9dfe74c6cab12171992a40add9a65e5bba92ac93063a4ac0eeba58c77e774a.png)
](https://twitter.com/GazeboSim)


If ` true ` the sensor will always measure force and torque. If ` false ` the
sensor will only update if there is a subscriber connected to the sensor's
topic. This setting is important when accessing the sensor through code. Calls
to [ ` ForceTorqueSensor::Torque() ` ](http://osrf-
distributions.s3.amazonaws.com/gazebo/api/7.1.0/classgazebo_1_1sensors_1_1ForceTorqueSensor.html#a050a369346fb2d338ae956b2fc01b7a0)
or [ ` ForceTorqueSensor::Force() ` ](http://osrf-
distributions.s3.amazonaws.com/gazebo/api/7.1.0/classgazebo_1_1sensors_1_1ForceTorqueSensor.html#ad578fc59083b6ceca7924d2335402d55)
will return stale data if there are no subscribers. This can be detected by
checking if [ ` IsActive() ` ](http://osrf-
distributions.s3.amazonaws.com/gazebo/api/7.1.0/classgazebo_1_1sensors_1_1ForceTorqueSensor.html#aa58bb55f74716e3435ae09ed212df26f)
returns ` false ` . Code can make a sensor update with no subscribers by
calling [ ` SetActive(true) ` ](http://osrf-
distributions.s3.amazonaws.com/gazebo/api/7.1.0/classgazebo_1_1sensors_1_1Sensor.html#a9a22d0e822e1d2bcd03c8594a0f5a40b)
.


[ **answered 2018-08-09 15:38:36 -0500  ** ](/answers/300191/revisions/)


|  [ Ask Your Question ](/questions/ask/)
---|---|---|---

0


**Note: Measurements near joint limits may jump depending on physics engine
parameters. See[ issue #2209 ](https://github.com/osrf/gazebo/issues/2209) **


#  Applying force and torque examples


###  After applying a force to the link


####  ` <frame> `


[ **asked 2016-09-06 03:24:09 -0500  ** ](/questions/243173/revisions/)


[ Where effort joint values come from ](/question/306958/where-effort-joint-
values-come-from/)


gz topic --view /gazebo/default/model_1/joint_01/force_torque/wrench


Toggle navigation  [
![gazebo](/assets/masthead-0bd44817978df8069f427d8ca1657998789065a2b242edfd1a3d8ab4a329dd4c.png)
](/)


> **Note** : Torque is always applied about the center of mass.


simulation: we already have the possibility to easily
simulate different robot models but it is still difficult
to simulate multiple instances of the same robot. Furthermore, since our robots in IIT have flexible joints,
we are investigating on how to simulate flexible joints
without specifying extra joints/links inside the SDF of
the robot. Finally we are planning an official release of
our plugins inside the Gazebo community.
References
D. Calisi, A. Censi, L. Iocchi, and D. Nardi. OpenRDK: a modular framework for robotic software
development. In Proceedings of International Conference on Intelligent Robots and Systems (IROS),
pages 1872–1877, September 2008. ISBN 978-1-
4244-2057-5. doi: 10.1109/IROS.2008.4651213.
DARPA. Darpa robotics challenge, 2013. URL http:
//www.theroboticschallenge.org/.
Rosen Diankov. Automated Construction of Robotic
Manipulation Programs. PhD thesis, Carnegie Mellon University, Robotics Institute, August 2010.
Coumans Erwin. Bullet, 2003. URL http://www.
bulletphysics.org/.
Roy Featherstone. Rigid Body Dynamics Algorithms.
Springer-Verlag New York, Inc., Secaucus, NJ, USA,
2007. ISBN 0387743146.
Brian P. Gerkey, Richard T. Vaughan, and Andrew
Howard. The player/stage project: Tools for multirobot and distributed sensor systems. In In Proceedings of the 11th International Conference on
Advanced Robotics, pages 317–323, 2003.
Serena Ivaldi, Vincent Padois, and Francesco Nori.
Tools for dynamics simulation of robots: a survey
based on user feedback. CoRR, abs/1402.7050, 2014.
Fumio Kanehiro, Hirohisa Hirukawa, and Shuuji Kajita. Openhrp: Open architecture humanoid robotics
platform. I. J. Robotic Res., 23(2):155–165, 2004.
Nathan Koenig and Andrew Howard. Design and
use paradigms for gazebo, an open-source multirobot simulator. In Intelligent Robots and Systems,
2004.(IROS 2004). Proceedings. 2004 IEEE/RSJ
International Conference on, volume 3, pages 2149–
2154, 2004.
G. Metta, P. Fitzpatrick, and L. Natale. Yarp: Yet
another robot platform. International Journal of
Advanced Robotics Systems, special issue on Software Development and Integration in Robotics, 3(1),
2006.
Olivier Michel. Cyberbotics ltd. webots tm : Professional mobile robot simulation. Int. Journal of
Advanced Robotic Systems, 1:39–42, 2004.


Seen: **1,798 times**


[ Masoud ](/users/26841/masoud/)
39  ●  14  ●  15  ●  18


While the SDF schema allows a ` <sensor> ` tag to be placed on either a link
or a joint, the force/torque sensor only works on joints. If the sensor is
added to a link, running gazebo with ` --verbose ` shows the following error:


[ Hi there! Please sign in
](/account/signin/?next=/question/243173/interpretation-of-forcetorque-sensor-
using-gazebo_ros_ft_sensor-plugin/) [ help ](/help/ "help")


    forceJointZ = mass * g
                = 10 kg * -9.8 m/s^2
                = -98 N


the simulated clock, this allows to run simulations
both slower and faster than real time and still have
synchronization between threads and controls. In any
case, when accessing the simulated clock Experiments
showed the approach to be successful in synchronizing
1kHz control loops against simulations running 1kHz,
thus having a 1ms clock granularity.
3.3.5 Simulation Description Format (SDF)
Gazebo uses an XML-style format, Simulation Description Format (SDF), to save and load information
(a) Gazebo interface with iCub
(b) A yarpscope showing on-line the acceleration measured by
the simulated IMU along z
0 50 100 150 200 250 300 350 400 450 500
−2
0
2
4
6
8
10
12
Accelerations measured IMU
ms
m/s
2
(c) Plot of accelerations measured by the IMU (data logged
during simulation). Accelerations along x,y and z are respectively in red, green and blue
Figure 7: iCub inside Gazebo.
about a simulated world or model. An SDF encapsulates all the necessary information for a simulation
such as:
• Scene: ambient lighting, sky properties, shadows.
• Physics: gravity, time step, physics engine.
• Models: collection of links, collision objects,
joints, and sensors.
• Lights: point, spot, and directional light sources.
• Plugins: world, model, sensor, and system plugins.
Our Control Board, Force Torque sensor and IMU
plugins are included inside the SDF file that describes our robots. For our humanoid bipedal robot,
COMAN, we have five Control Board plugins (one
for each kinematic chain), four Force/Torque sensor


> **Tip** : The pink circles are attached to the highlighted arrow. To rotate
> the other arrow, first click it to attach the circles to it and then drag
> them normally.


            </sensor>
          </joint>
        </model>
      </world>
    </sdf>


####  ` <visualize> `


I'm using gazebo 2.2.3 + Ros indigo running in ubuntu 14.04.


[ How to subscribe to a topic whom type is gazebo_msg/ContactState
](/question/244380/how-to-subscribe-to-a-topic-whom-type-is-
gazebo_msgcontactstate/)


The above example places a force/torque sensor on a revolute joint. However,
real force/torque sensors are typically rigidly mounted to another rigid body.
A real sensor could not measure the force and torque exactly at the revolute
joint origin. Modeling this way is reasonable if the real sensor is close
enough to the joint that the error from the offset is negligible.


I realize this is an old post, however I found that the torque/force plugin
for gazebo was giving very large values even when my model was stationary.
Generating better inertial values made the reported values much better ( [
http://answers.gazebosim.org/question...
](http://answers.gazebosim.org/question/4372/the-inertia-matrix-explained) )


[ tags ](/tags/) [ users ](/users/) [ badges ](/badges/)


If ` true ` the gazebo client will show a visualization of the force and
torque at the joint.


####  ` <topic> `


[ Has anyone ever used ATI wireless F/T sensor ? ](/question/262641/has-
anyone-ever-used-ati-wireless-ft-sensor/)


ROS Resources: [ Documentation ](http://wiki.ros.org/) | [ Support
](http://wiki.ros.org/Support) | [ Discussion Forum
](http://discourse.ros.org/) | [ Index ](http://index.ros.org/) | [ Service
Status ](http://status.ros.org/) | [ ros @ Robotics Stack Exchange
](https://robotics.stackexchange.com/questions/tagged/ros)
---

_Attention:_ Answers.ros.org is deprecated as of August the 11th, 2023. Please
visit [ robotics.stackexchange.com ](http://robotics.stackexchange.com) to ask
a new question. This site will remain online in read-only mode during the
transition and into the foreseeable future. Selected questions and answers
have been migrated, and redirects have been put in place to direct users to
the corresponding questions on Robotics Stack Exchange. Additional details are
[ available here ](https://discourse.ros.org/t/ros-and-gazebo-answers-
migration-to-robotics-stack-exchange-process/31494) .


The value of this element may be one of: ` child ` , ` parent ` , or ` sensor
` . It is the frame in which the forces and torques should be expressed. The
values ` parent ` and ` child ` refer to the parent or child links of the
joint. The value ` sensor ` means the measurement is rotated by the rotation
component of the ` <pose> ` of this sensor. The translation component of the
pose has no effect on the measurement.


###  At the start of the world


The arrows directions will always match the directions specified in the
dialog. From the dialog, the direction can be changed by editing the numbers
on the ` XYZ ` fields. From the scene, the direction can be changed by
dragging the pink circles around the arrows.


Asked: ** 2016-09-06 03:24:09 -0500  **


Please note: ROS Answers requires javascript to work properly, please enable
javascript in your browser, [ here is how
](https://www.google.com/support/bin/answer.py?answer=23852)


##  Question Tools


####  ` <update_rate> `


    <?xml version="1.0"?>
    <sdf version="1.6">
      <world name="default">
        <physics name="default_physics" default="0" type="ode">
          <max_step_size>0.001</max_step_size>
          <real_time_factor>1</real_time_factor>
          <real_time_update_rate>1000</real_time_update_rate>
          <ode>
            <solver>
              <type>quick</type>
              <iters>50</iters>
              <sor>1.0</sor> <!-- Important, see issue #2209 -->
              <use_dynamic_moi_rescaling>false</use_dynamic_moi_rescaling>
            </solver>
          </ode>
        </physics>
        <include>
          <uri>model://ground_plane</uri>
        </include>
        <include>
          <uri>model://sun</uri>
        </include>
        <model name="model_1">
          <link name="link_1">
            <pose>0 0 2.0 0 0 0</pose>
            <inertial>
              <inertia>
                <ixx>0.100000</ixx>
                <ixy>0.000000</ixy>
                <ixz>0.000000</ixz>
                <iyy>0.100000</iyy>
                <iyz>0.000000</iyz>
                <izz>0.100000</izz>
              </inertia>
              <mass>10.000000</mass>
            </inertial>
            <visual name="visual_sphere">
              <geometry>


  * [ Tutorials ](/tutorials)
  * [ Download ](/download)
  * [ Blog ](/blog.html)
  * [ Media ](/media)
  * [ Projects ](/projects)


I also tried to reduce Gaussian Noise of the sensor by adding `
<gaussianNoise>0.0</gaussianNoise> ` to the plugin tag. but this didn't solve
the problem.


  *[
              2016-09-06 03:24:09 -0500
             ]: 2016-09-06 03:24:09 -0500
  *[
              2016-09-06 03:30:16 -0500
             ]: 2016-09-06 03:30:16 -0500
  *[
              2018-08-09 15:38:36 -0500
             ]: 2018-08-09 15:38:36 -0500
  *[
        2016-09-06 03:24:09 -0500
       ]: 2016-09-06 03:24:09 -0500
  *[
        2024-04-18 18:57:03 -0500
       ]: 2024-04-18 18:57:03 -0500


[ Distance measurements and tf ](/question/10603/distance-measurements-and-
tf/)


    <sensor name="my_cool_sensor" type="force_torque">
      <force_torque>
        <frame>child</frame>
        <measure_direction>child_to_parent</measure_direction>
      </force_torque>
    </sensor>


[ Edit
](https://github.com/osrf/gazebo_tutorials/blob/master/force_torque_sensor/tutorial.md)
Version: 7.0+


If this error is not negligible, the rigid body can be split into two links
with a fixed joint at the location of the real sensor.


##  Rotation tool


> **Note** : If you apply force and/or torque while the simulation is paused,
> they will accumulate and be applied all at once when the simulation is
> unpaused.


###  Create a world with a force/torque sensor


[ ros2 gazebo camera not publishing data ](/question/371730/ros2-gazebo-
camera-not-publishing-data/)


[ Has anyone connected more than 3 sensors to ROS? If so, how can we manage
it? Is it advisable to use a usb splitter? ](/question/172621/has-anyone-
connected-more-than-3-sensors-to-ros-if-so-how-can-we-manage-it-is-it-
advisable-to-use-a-usb-splitter/)


Now let's apply force to the box. Right-click the box in the scene and choose
` Apply Force/Torque ` . A new dialog will pop up.


This tutorial will explain how to apply force and/or torque to models during
simulation using the graphical user interface.


edit


First time here? Check out the FAQ!


The mass supported by the joint remains the same, so the magnitude of the
force is the same. The direction of the force changes to be +98 N on the Y
axis. Because the sphere is positioned 1.5 m away on the joint's Z axis the
torque about the X axis is:


  $(sort -u $(find . -iname 'packages-'`lsb_release -cs`'.apt' -o -iname 'packages.apt' | grep -v '/\.git/') | sed '/gz\|sdf/d' | tr '\n' ' ')
Building the Gazebo Libraries
Once the compiler and all the sources are in place it is time to compile them. Start the procedure by changing into the workspace and listing the packages recognized by colcon:
cd ~/workspace/
colcon graph
colcon graph should list the Gazebo libraries with an interdependency diagram. If that is the case, then you are ready to build the whole set of libraries:
colcon build --merge-install
To speed up the build process, you could also disable tests by using
colcon build --cmake-args -DBUILD_TESTING=OFF --merge-install
To use debuggers activate debug symbols. Gazebo will run slower, but you'll be able to use GDB:
colcon build --cmake-args ' -DBUILD_TESTING=OFF' ' -DCMAKE_BUILD_TYPE=Debug' --merge-install
To build a specific package with all its dependent packages:
colcon build --merge-install --packages-up-to PACKAGE_NAME
To build a single package:
colcon build --packages-select PACKAGE_NAME
Visit colcon documentation to view more colcon build and test options.
If there are no errors, all the binaries should be ready to use. You can check the Troubleshooting section for errors.
Using the workspace
The workspace needs to be sourced every time a new terminal is used.
Run the following command to source the workspace in bash:
. ~/workspace/install/setup.bash
Or in zsh:
. ~/workspace/install/setup.zsh
This is the end of the source install instructions; head back to the Getting started page to start using Gazebo!
Uninstalling source-based install
A source-based install can be "uninstalled" using several methods, depending on the results you want:
If you installed your workspace with colcon as instructed above, "uninstalling" could be just a matter of opening a new terminal and not sourcing the workspace's setup.sh. This way, your environment will behave as though Gazebo is not installed on your system.
If, in addition to not wanting to use the libraries, you're also trying to free up space, you can delete the entire workspace directory with:
rm -rf ~/workspace
If you want to keep the source code, you can remove the install / build / log directories as desired, leaving the src directory.
Troubleshooting
See Troubleshooting
QML Debugging
To perform QML debugging you'll need:
Add --cmake-args -DDQT_QML_DEBUG flag to colcon
QtCreator
You will need to build Gazebo with:
colcon build --cmake-args -DQT_QML_DEBUG --merge-install
Note: Advanced users may note that only the gz-sim project needs this flag.
After that's done, launching gz sim -g will result in the following message:


####  Table of Contents


##  Force


* [ torque ](/questions/scope:all/sort:activity-desc/tags:torque/page:1/)


add a comment


I've successfully added a force torque/sensor to my model by adding following
codes in my urdf file:


    torqueJoint01_x = r X R
                    = ||r|| * ||F|| * sin(theta)
                    = distanceZ * (massLink * g) * sin(theta)
                    = 1.5 m * (10 kg * 9.8 m/s^2) * sin(-90)
                    = -147 Nm


* **X, Y, Z** : Each field specifies how much torque will be applied about that axis. The frame is fixed to the link.


Gazebo is open-source licensed under [ Apache 2.0
](http://www.apache.org/licenses/LICENSE-2.0.html)


##  Apply force with an offset


[Err] [Link.cc:114] A link cannot load a [force_torque] sensor.


On ` Apply to link ` , select ` arm_elbow_pan ` , the arrows will move to this
link. Under torque, write ` 100 Nm ` on the ` Z ` field and press ` Apply
Torque ` a few times to see the arm rotate slightly.


##  Torque


Toggle navigation  [
![gazebo](/assets/masthead-0bd44817978df8069f427d8ca1657998789065a2b242edfd1a3d8ab4a329dd4c.png)
](/)


[ ![ROS Answers logo](/m/ros/media/images/logoros.png?v=28) ](/questions/)


Interpretation of Force/Torque Sensor using gazebo_ros_ft_sensor plugin


other YARP modules with the simulation time.
3.3.1 Control Board
The Control Board plugin allows to control the robot
using YARP Interfaces, it is implemented as a Gazebo
Model plugin. Every control board allows the user to
control one or more joints (a kinematic chain such as
the arm or leg, etc.) as specified in a configuration
file. For each controlled joint the control board opens
different interfaces, permitting the use of different type
of controllers for each joint. Such interfaces include position control, torque control, encoders reading, torque
(a) Gazebo interface with COMAN
(b) A yarpscope showing on-line the forces and the torques at
each Force/Torque sensor
0 50 100 150 200 250 300 350 400 450 500
−5
0
5
10
15
20
25
30
35
40
Forces Right Arm
ms
N
(c) Plot of forces measured at the Force/Torque sensor placed
on the right arm (data logged during simulation). Forces along
x,y and z are respectively in red, green and blue
0 50 100 150 200 250 300 350 400 450 500
−0.2
0
0.2
0.4
0.6
0.8
1
1.2
Torques Right Arm


Save this world as [ ` force_torque_tutorial.world `
](https://github.com/osrf/gazebo_tutorials/raw/master/force_torque_sensor/files/force_torque_tutorial.world)
.


plugins (two in the legs and two in the arms) and
one IMU sensor plugin (placed on the back of the
waist). The SDF descriptions of COMAN and iCub
are available in https://github.com/EnricoMingo/
iit-coman-ros-pkg and in https://github.com/
robotology-playground/icub_gazebo respectively.
The clock plugin is loaded trough a command line
parameter when the simulator is started.
4 Conclusions
In this work we have presented a set of Gazebo plugins,
named gazebo yarp plugins, that allow to connect the
robotics framework YARP to Gazebo itself. Gazebo
was chosen since it is easy to use, it has the possibility
to switch between different rigid multi-body dynamics
engines, it is Open-Source and has an active community. Our plugins are based on YARP device drivers
in order to have exactly the same interfaces in the
real and simulated robot. This allows to write modules
that will work both in the simulator and in the real
robot without the need to change the code. This is
a very important paradigm in robotics research and
develop since it minimizes the presence of errors due
to code porting. Furthermore the simulator becomes a
tool that helps the developer in testing and validation
before using the real platform. Such plugins consist in:
a Control Board plugin to control the robot, a Force
Torque sensor plugin and an IMU plugin. A special
plugin dedicated to synchronization between modules
and simulator was also implemented. The plugins were
tested to simulate two humanoid bipedal robots, the
COMAN and the iCub, both from the Italian Institute
of Technology.
5 Future Works
Gazebo yarp plugins is a project at an early stage that
is gaining more and more interest inside the YARP
community. Beside the good results obtained up to
now, some works are still missing in order to be able
to have 100% compatibility with all the Gazebo functions. Furthermore we still need to implement plugins
to connect YARP device drivers dedicated to cameras
and RGB-D sensors to the simulated ones in Gazebo.
We are also interested in multi-robot and human-robot


* **Clear** : Pressing this button will zero the ` X ` , ` Y ` , ` Z ` and ` Mag ` fields.


[ ALL ](/questions/scope:all/sort:activity-desc/page:1/) [ UNANSWERED
](/questions/scope:unanswered/sort:answers-asc/page:1/)


[ Change rviz opengl version on Qt app, python ](/question/370940/change-rviz-
opengl-version-on-qt-app-python/)


####  ` <measure_direction> `


* **Apply Torque** : Click this to apply only torque for one time step. Keep in mind that time steps are in the order of milliseconds, so relatively large torques are needed in order to apply a significant angular impulse.


Applying a force to ` link_1 ` causes it to topple over and rest at a 90
degree angle, the limit of the joint. The limit is what keeps the sphere
suspended above the ground plane. The joint's +Y axis points towards the
ground plane. Gravity acting on the sphere applies a torque about the X axis.


add a comment


collection of Gazebo plugins.
3 Structure
It is useful to understand Gazebo plugins and YARP
device drivers before describing the structure of our
plugins (from now on gazebo yarp plugins).
Gazebo plugins are C++ classes that extend the
functionalities of Gazebo, while YARP device drivers
are C++ classes used in YARP for abstracting the
functionality of robot devices. Usually, each class of
gazebo yarp plugins embeds a YARP device driver in
a Gazebo plugin.
3.1 Gazebo Plugins
A plugin is a piece of code compiled as a shared
library and inserted into the simulator. A plugin has
direct access to all the functionalities of Gazebo from
the physics engine to the simulated world. Furthermore, plugins are self-contained routines that are easily shared and can be inserted and removed from a running system. There are 4 types of plugins in Gazebo:
world, model and sensor plugins are attached to
and control a specific simulated world/model/sensor
respectively, while system plugin is specified on the
command line and loads during the Gazebo startup.
3.2 YARP Device Drivers
In YARP, a device driver is a class that implements one
or more interfaces. There are three separate concerns
related to devices in YARP:
• Implementing specific drivers for particular devices
• Defining interfaces for device families
• Implementing network wrappers for interfaces
For example the Control Board device driver implements a set of interfaces that are used to control
the robot (IPositionControl, ITorqueControl, etc.) and
another set of interfaces to read data from the motors
(IEncoders, etc).
3.3 Gazebo-YARP Plugins
The gazebo yarp plugins is made of:
• Gazebo plugins that instantiate YARP device
drivers,
• YARP device drivers that wrap Gazebo functionalities inside the YARP device interfaces.
The plugins/devices already implemented are the Control Board, 6-axis Force Torque sensor, Inertial Measurement Unit (IMU) and a Clock plugin used for
synchronization. The first three plugins are directly
related to the simulated objects and sensors, while the
last one is a system plugin that synchronizes all the


[ __ ](/questions/) |


The force/torque sensor does not currently support this parameter.


##  Apply All


#  Force/Torque Sensor


[ how to control a 6 dof manipulator to write words on a wall through moveit
simulation ](/question/257026/how-to-control-a-6-dof-manipulator-to-write-
words-on-a-wall-through-moveit-simulation/)


* **Application point** : By default, force is applied to the link's center of mass. Here you can edit the ` X ` , ` Y ` and ` Z ` fields to give the force an offset with respect to the link's origin expressed in the link's frame. Select ` Center of mass ` again to fill the ` XYZ ` fields with its coordinates.


[ Edit
](https://github.com/osrf/gazebo_tutorials/blob/master/apply_force_torque/tutorial.md)
Version: 6.0+


  * [ Tutorials ](/tutorials)
  * [ Download ](/download)
  * [ Blog ](/blog.html)
  * [ Media ](/media)
  * [ Projects ](/projects)


####  ` <frame> `


###  View the output of the force/torque sensor


Force and torque are applied at the same time, i.e. apply a wrench. Hold enter
or click it repeatedly to apply multiple times.


Tikhanoff et al. [2008]) that is dedicated to a specific platform. The needs of a more generic tool for
simulating different robots rise up. Gazebo, which has
been recently chosen as the simulator for the DARPA
Virtual Robotic Challenge (VRC, DARPA [2013]), allows the use of different dynamic engines, it is easily
expandable through plugins and it has a strong and
active community. Gazebo is maintained by the Open
Source Robotics Foundation (OSRF [2011]).
This paper is organized in the following sections: State
of Art, discusses some of the most popular simulation
environments in robotics, Structure introduces in
detail the Gazebo plugins developed in this work,
Conclusions summarize the outcome of this effort
and finally Future Works discusses the follow up
activities.
2 State of Art
A large number of simulators have been developed
in the past two decades (Ivaldi et al. [2014]). Such
simulators range from dynamic solver libraries to complex simulation environments/systems. The latter are
usually large projects that provide both rigid body dynamic simulations and tools such as graphical editors,
planner libraries, visualization tools, controllers and so
on.
The Open Dynamics Engine (ODE, Smith [2000]) is
one of the most widely used rigid body dynamics
engine in robotics simulation. ODE simulates chains
of rigid bodies connected and constrained by different types of joints. It has a built-in collision detection system and implements hard contacts using nonpenetration constraint whenever two bodies collide.
Beside the large number of project that use it, at the
moment the development has been paused. Bullet (Erwin [2003]) is another dynamic engine. It implements
different direct/inverse rigid body dynamic algorithms
(eg. Featherstone articulated body algorithm, Featherstone [2007]) as well as different solvers (eg. Mixed
Linear Complementarity Problem, MLCP) and contact models. Bullet is used for a wide range of projects
and its community is active and continues to improve
it constantly.
OpenRAVE (Diankov [2010]) provides an environment
for testing, developing, and deploying motion planning
algorithms in real-world robotics applications. The
main focus is on simulation and analysis of kinematic
and geometric information related to motion planning.
It provides many command line tools to work with
robots and planners, and the run-time core is small
enough to be used inside controllers and bigger frameworks. Industrial robotics automation is an important


* **Mag** : The total magnitude of the torque which will be applied, which is the Euclidean norm of the 3 torques above. Changing the magnitude changes the ` XYZ ` fields proportionally, maintaining the torque direction.


* [ noise ](/questions/scope:all/sort:activity-desc/tags:noise/page:1/)


Under ` Force ` , type ` 1000 N ` on the ` X ` field. Then under ` Application
point ` , press the up arrow in the ` Y ` field until it reaches ` 1 m ` ,
you'll see the arrow moving as you do it. Press ` Enter ` a few times to and
the box will rotate. Hold ` Enter ` to repeatedly apply the force and make the
box spin faster.


Let's go through an example of applying force and torque to simple models.
Open Gazebo and from the insert tab, insert a ` Simple Arm ` into the scene.
Then, from the top toolbar, insert a box. Make sure the simulation is not
paused.


#  Modeling a Real Force/Torque Sensor


** WARNING ** : This documentation is for Gazebo-classic, which has been
superseded by Gazebo. [ Click here to see the documentation for the latest
Gazebo release ](https://gazebosim.org/docs)


QML debugging is enabled. Only use this in a safe environment.
QML Debugger: Waiting for connection on port 40000...
After that you can just head to QtCreator -> Debug -> Start Debugging -> Attach to QML Port... and enter the QML port
Once you click there, set the port number to 40000 and hit ok
We're working to improve QtCreator integration so that it works out of the box.
The ruby gz script doesn't yet pass the necessary command line arguments to the application.
Note that because all instances will try to use port 40000, only one instance can use it. If you shutdown the process and restart it immediately too quickly, the OS may still claim the port is in use and hence the 2nd (re)launch will not listen to QML debugger attach requests.
Avoid QML stall waiting for debugger on startup
During development, you may find troublesome that gz sim -g won't actually start until QtCreator hooks to the QML Debugging port.
If that's a problem, you can edit the C++ file gz-sim/src/gz.cc and remove block from it. E.g.
// The following:
const_cast<char *>(
      "-qmljsdebugger=port:40000,block,services:DebugMessages,QmlDebugger,"
      "V8Debugger,QmlInspector,DebugTranslation")
// Must become the following
const_cast<char *>(
      "-qmljsdebugger=port:40000,services:DebugMessages,QmlDebugger,"
      "V8Debugger,QmlInspector,DebugTranslation")
Source Installation on Ubuntu
Install tools
Generic tools
vcstool and colcon from pip
vcstool and colcon from apt
Git
Getting the sources
Install dependencies
Building the Gazebo Libraries
Using the workspace
Uninstalling source-based install
Troubleshooting
QML Debugging
Avoid QML stall waiting for debugger on startup
Brought to you by Open Robotics.
Except where otherwise noted, the gazebosim.org web pages are licensed under Creative Commons Attribution 3.0.


###  Apply forces and torques in gazebo


#  Introduction


[ ![cc-by-sa](/m/default/media/images/cc-by-sa.png?v=28)
](http://creativecommons.org/licenses/by-sa/3.0/legalcode) ROS Answers is
licensed under Creative Commons Attribution 3.0 Content on this site is
licensed under a [ Creative Commons Attribution Share Alike 3.0
](http://creativecommons.org/licenses/by-sa/3.0/legalcode) license.


[ Powered by Askbot version 0.10.2 ](http://askbot.com)


* **X, Y, Z** : Each field specifies how much force will be applied on that direction. The frame is fixed to the link.


FEATURES
SHOWCASE
DOCS
COMMUNITY
MORE
APP
Docs / Gazebo Harmonic
Supported Sep, 2023 to Sep, 2028
LTS
Harmonic (LTS)
Release
Get Started
Install
Binary Ubuntu Install
Binary Macos Install
Binary Windows Install
Ubuntu Source Install
Macos Source Install
Windows Source Install
Troubleshooting
Tutorials
Migration From Ignition
Feature Comparison
Ros/gazebo Installation
Migration From Ros 2 Gazebo Classic
Roadmap
Release Features
Releases
Development
Sim Architecture
Fuel
Library Reference


####  ` <always_on> `


The site is read-only. Please transition to use Robotics Stack Exchange


##  1  Answer


On the dialog, write ` 100 N ` on the ` Y ` field under ` Force ` and press `
Enter ` , the arm will start rotating slightly. The force was applied in the
link's ` Y ` direction for a single time-step, which is in the order of
milliseconds, thus the need for such a large force.


####  Table of Contents


Floating point numbers separated by spaces with this order ` x y z roll pitch
yaw ` . It describes the location of the sensor frame with respect to the
parent joint.


ms
Nm
(d) Plot of torques measured at the Force/Torque sensor placed
on the right arm (data logged during simulation). Torques
along x,y and z are respectively in red, green and blue
Figure 3: A Gazebo simulation running COMAN
interacting with a debris
measurement and joint impedance control. Usually the
number of instantiated control boards is equal to the
number of kinematic chains. Each control board, during every cycle of simulation, reads position, velocity
and torque values from the simulated joints and sends
desired joints position or torques to the simulator.
The values read from the simulator are broadcasted
through YARP interfaces in the YARP network, in a
similar way the desired joint values come from YARP
interfaces (Figure 4). The following YARP interfaces
are used to control the robot.
• IPositionControl: a position control with a linear trajectory generator considering a max joint
speed
• IPositionDirect: a position control using Gazebo
position PIDs
• ITorqueControl: a perfect torque follower
• IImpedanceControl: a joint impedance control
with the following law
τd = −Pd(q − qd) − Ddq˙ + τof f set (1)
where qd is the desired equilibrium position, Pd is
the desired joint stiffness and Dd is the desired
joint damping. τof f set is an extra signal that
can be used for gravity compensation or inverse
dynamics control.
Furthermore, the Control Board implements the IControlMode interface that allows to change the type of
controller online. All these interfaces are also available
on the robot and they have the same behaviour.
Figure 4: Control Board plugin for the left arm
kinematic chain. yarp::IPositionControl interface has
a method positionMove() that can be used to set joint
values inside a YARP module. The plugin implements
such interface by calling the Publish() method inside
the Gazebo API to move the simulated joints at each
OnUpdate().


[ Apply a force ](tutorials?tut=apply_force_torque) to ` link_1 ` of 500 N in
the +Y direction. Observe the output in the topic viewer window.


[ ![Google+](/assets/google_gray-
cc34826f560f99c7a9b7db88cd5f2db4d28fd4b3afcfa4b897435c51e3b25518.png)
](//plus.google.com/u/0/115981436296571800301?prsrc=3) [
![YouTube](/assets/youtube_gray-978838444154eb6aa5e4aa38489f66d10e40361dd06a3814411c211cba013752.png)
](https://www.youtube.com/channel/UCJyqf9XJpDoM9XnpAwW6WxA) [
![YouTube](/assets/twitter_gray-8e9dfe74c6cab12171992a40add9a65e5bba92ac93063a4ac0eeba58c77e774a.png)
](https://twitter.com/GazeboSim)


* [ Sensor ](/questions/scope:all/sort:activity-desc/tags:Sensor/page:1/)


OSRF. Open source robotics foundation, 2011. URL
http://osrfoundation.org/.
Morgan Quigley, Ken Conley, Brian P. Gerkey, Josh
Faust, Tully Foote, Jeremy Leibs, Rob Wheeler,
and Andrew Y. Ng. Ros: an open-source robot
operating system. In ICRA Workshop on Open
Source Software, 2009.
Eric Rohmer, Surya P. N. Singh, and Marc Freese.
V-rep: A versatile and scalable robot simulation
framework. In IROS, pages 1321–1326. IEEE, 2013.
Michael A. Sherman, Ajay Seth, and Scott L. Delp.
Simbody: multibody dynamics for biomedical research. Procedia {IUTAM}, 2(0):241 – 261, 2011.
ISSN 2210-9838.
Russel Smith. Open dynamic engine, 2000. URL
http://www.ode.org/.
Georgia Tech. Dart, 2013. URL http://dartsim.
github.io/.
V. Tikhanoff, A. Cangelosi, P. Fitzpatrick, G. Metta,
L. Natale, and F. Nori. An open-source simulator
for cognitive robotics research: The prototype of
the icub humanoid robot simulator. In Proceedings
of the 8th Workshop on Performance Metrics for
Intelligent Systems, PerMIS ’08, pages 57–61, New
York, NY, USA, 2008. ACM. ISBN 978-1-60558-
293-1. doi: 10.1145/1774674.1774684. URL http://
doi.acm.org/10.1145/1774674.1774684.
Emanuel Todorov, Tom Erez, and Yuval Tassa. Mujoco: A physics engine for model-based control. In
IROS, pages 5026–5033. IEEE, 2012. ISBN 978-1-
4673-1737-5.


###  Force/Torque specific parameters


Follow


* [ force ](/questions/scope:all/sort:activity-desc/tags:force/page:1/)


[ subscribe to rss feed ](/feeds/question/243173/ "subscribe to the rss feed")


> **Tip** : Right-click the model and choose ` View -> Center of mass ` to see
> its position. You might want to also make the model transparent for that.


[ Issue subscribing to topic that is populated from
libgazebo_ros_ray_sensor.so ](/question/377045/issue-subscribing-to-topic-
that-is-populated-from-libgazebo_ros_ray_sensorso/)


1 follower


[ Back ](/tutorials?cat=sensors)


gazebo --verbose force_torque_tutorial.world


[ KurtR ](/users/36914/kurtr/)
16  ●  1


[ ![gvdhoorn gravatar image](/upfiles/avatars/gvdhoorn/resized/32/4550046.png)
](/users/5184/gvdhoorn/)


[ ![Masoud gravatar image](/upfiles/avatars/Masoud/resized/32/Shiraz.png)
](/users/26841/masoud/)


This tutorial describes how to use a force/torque sensor on a joint. This
sensor publishes force and torque readings to a topic.


#  Understanding the Force/Torque Sensor


#  Applying Force/Torque


[ Back ](/tutorials?cat=tools_utilities)


represents the real robot at the interface level (Figure 1). Such simulator module accepts control input
(desired joint torques, desired joint position, ...) and
outputs sensory feedback (cameras, joint positions, ...)
from the simulated world. These simulators usually
allow to have the human in-the-loop permitting to
train a human operator. The most important aspect is
that they allow to develop modules that directly will
work in the real robot without any need to rewrite
code. In fact, when the real robot is used, there is a
module that replaces the simulator by providing the
same hardware interfaces.
By accurately simulating robots and environments,
code designed to operate on a real robot can be
executed and validated on the simulated equivalent
system. This avoids common problems associated with
(a) Module A connected to the simulator
(b) Module A connected to the robot
Figure 1: Module A write desired joint position
and read actual joint position without knowing if it is
interfaced with the simulator or the robot since they
expose the same interface.
hardware such as short battery life, hardware failures,
and unexpected and dangerous behaviors, particularly
during the initial stages of development and tuning of
new modules and controllers. It is also much faster to
have a simulation engine up and running than using a
real robot, especially when the simulation engine can
run faster than real-time. In this way the simulator
becomes a fundamental part of the framework and
the robot software development cycle as the first step
to validate algorithms, thus minimizing the risks of
hardware breaks.
Figure 2: COMAN and iCub interacting inside a
Gazebo simulation of a kitchen. Blue dots represent
contact points.
With these concepts in mind we decided to extend
one of the most known robotics simulator, Gazebo
(Koenig and Howard [2004]), to be compatible with
one of the most used robotics framework, YARP (Figure 2), developed in the Italian Institute of Technology.
YARP is supported by the iCub simulator (iCubSim,


* **Mag** : The total magnitude of the force which will be applied, which is the Euclidean norm of the 3 forces above. Changing the magnitude changes the ` XYZ ` fields proportionally, maintaining the force direction.


                <sphere>
                  <radius>0.100000</radius>
                </sphere>
              </geometry>
            </visual>
            <visual name="visual_cylinder">
              <pose>0 0 -0.75 0 0 0</pose>
              <geometry>
                <cylinder>
                  <radius>0.0100000</radius>
                  <length>1.5</length>
                </cylinder>
              </geometry>
            </visual>
            <collision name="collision_sphere">
              <max_contacts>250</max_contacts>
              <geometry>
                <sphere>
                  <radius>0.100000</radius>
                </sphere>
              </geometry>
            </collision>
          </link>
          <joint name="joint_01" type="revolute">
            <parent>world</parent>
            <child>link_1</child>
            <pose>0 0 -1.5 0 0 0</pose>
            <axis>
              <limit>
                <lower>-1.57079</lower>
                <upper>1.57079</upper>
              </limit>
              <dynamics>
                <damping>0.000000</damping>
                <friction>0.000000</friction>
              </dynamics>
              <xyz>1.000000 0.000000 0.000000</xyz>
            </axis>
            <sensor name="force_torque" type="force_torque">
              <update_rate>30</update_rate>


3.5
4
4.5
5
5.5
x 10−3
thread loop cycles
telapsed [s]
Thread Rate in Wall Clock Time
Thread Rate in Simulation Clock Time
Figure 6: Time elapsed between each execution of
the control loop, measured in simulation clock time
and in wall clock time. Desired thread rate is 1kHz
and simulation time step is 1ms
simulation. For instance if the simulation runs with a
real time factor of 0.1, 10 seconds are needed to simulate 1 real second. Within this situation, the controller
process should also be slowed down 10 times to be
coherent with the simulation. To solve this issue we developed a clock plugin that synchronizes modules with
the simulated time. The clock plugin is implemented
as a System plugin and publishes on a YARP port
the time information from the simulator. For every
simulation step, the simulation time is incremented
and the timestamp is sent via socket. All the YARP
threads implemented as control threads (which need
to be run at a desired rate, i.e. YARP’s RFModule or
RateThread) are automatically synchronized using the
simulation clock if the YARP CLOCK environment
variables is set, or if the module explicitly asks to.
The yarp::os::Time functionalities are also transparently working using the wall-clock or the simulation
clock depending on the environment variable. Thread
sleeps are performed using the right wall or simulated
time. When synchronized with the simulation clock
the yarp::os::Time delay does not explicitly sleep on
a wall clock, rather a scheduler is synchronized with
the simulation clock by performing blocking reads on
the YARP CLOCK port. This scheduler wakes up
the threads that required a delay just once, when
they have slept for the desired duration. Compared
to the ROS::Time implementation which uses small
sleeps on wall clock to check synchronization with


##  SDF parameters


Open a terminal and run this command:


    <gazebo reference="shoulder_pan_joint">
        <provideFeedback>true</provideFeedback>
    </gazebo>

    <gazebo>
        <plugin name="ft_sensor" filename="libgazebo_ros_ft_sensor.so">
            <updateRate>10.0</updateRate>
            <topicName>ft_sensor_topic</topicName>
            <jointName>shoulder_pan_joint</jointName>
        </plugin>
    </gazebo>


[ ![ gravatar image]() ]() [ ]() (  2024-04-18 18:57:03 -0500  )  edit


##  Apply torque to a link


[ none ](/questions/scope:all/sort:activity-desc/tags:none/page:1/) ×


Although the model is static and nothing is moving in gazebo gui, the outputs
of force/torque sensor published by "ft_sensor_topic" is fluctuating. For
example the force value that I expect to be -100 is fluctuating between -55 N
and -143N. Other 5 components of torque and force values are also fluctuating
in a similar range.


##  Stats


* **Clear** : Pressing this button will zero the ` X ` , ` Y ` , ` Z ` and ` Mag ` fields.


* **Apply Force** : Click this to apply only force for one time step. Keep in mind that time steps are in the order of milliseconds, so relatively large forces are needed in order to apply a significant impulse.


This is the rate in Hz that the sensor should update itself. It is the number
of messages that will be published by this sensor per simulated second.


[ ![KurtR gravatar
image](//www.gravatar.com/avatar/e3a59c43e9571cc13c91da2c148f3940?s=32&d=identicon&r=PG)
](/users/36914/kurtr/)


The force/torque sensor does not currently support this parameter.


###  Launch the world


[ **updated 2016-09-06 03:30:16 -0500  ** ](/questions/243173/revisions/)


####  ` <pose> `


[ PCL - coordinates from PointCloud2 message ](/question/265379/pcl-
coordinates-from-pointcloud2-message/)


Gazebo is open-source licensed under [ Apache 2.0
](http://www.apache.org/licenses/LICENSE-2.0.html)


[ gvdhoorn ](/users/5184/gvdhoorn/)
86574  ●  283  ●  1432  ●  1054  [ http://cor.tudelft.nl/
](http://cor.tudelft.nl/ "gvdhoorn's website is http://cor.tudelft.nl/")


A force/torque sensor is created by adding ` <sensor> ` tag with the attribute
` type ` set to ` force_torque ` . There are two additional parameters that
can be set.


##  Related questions


#  Quick Start


#  Saved searches


[ Report repository ](/contact/report-
content?content_url=https%3A%2F%2Fgithub.com%2Fros-
simulation%2Fgazebo_ros_pkgs&report=ros-simulation+%28user%29)


     [ Iron (latest) ](../../../../../iron/Tutorials/Advanced/Simulators/Gazebo/Gazebo.html)
     [ Humble ](Gazebo.html)
     [ Galactic (EOL) ](../../../../../galactic/index.html)
     [ Foxy (EOL) ](../../../../../foxy/index.html)
     [ Eloquent (EOL) ](../../../../../eloquent/index.html)
     [ Dashing (EOL) ](../../../../../dashing/index.html)
     [ Crystal (EOL) ](../../../../../crystal/index.html)


No packages published


[ plume.png ](/uuvsimulator/uuv_plume_simulator/blob/master/plume.png
"plume.png")


Cancel  Create saved search


##  Footer


  * [ ](../../../../index.html)
  * [ Tutorials ](../../../../Tutorials.html)
  * [ Advanced ](../../../Advanced.html)
  * [ Simulators ](../Simulation-Main.html)
  * [ Gazebo ](Simulation-Gazebo.html)
  * Setting up a robot simulation (Gazebo)
  * [ Edit on GitHub ](https://github.com/ros2/ros2_documentation/blob/humble/source/Tutorials/Advanced/Simulators/Gazebo/Gazebo.rst)


{{ message }}


* [ Pricing ](/pricing)


##  [ Packages  0
](/orgs/uuvsimulator/packages?repo_name=uuv_plume_simulator)


      * [ Reading from a bag file (C++) ](../../Reading-From-A-Bag-File-CPP.html)
      * [ Simulators ](../Simulation-Main.html)
        * [ Webots ](../Webots/Simulation-Webots.html)
          * [ Installation (Ubuntu) ](../Webots/Installation-Ubuntu.html)
          * [ Installation (Windows) ](../Webots/Installation-Windows.html)
          * [ Installation (macOS) ](../Webots/Installation-MacOS.html)
          * [ Setting up a robot simulation (Basic) ](../Webots/Setting-Up-Simulation-Webots-Basic.html)
          * [ Setting up a robot simulation (Advanced) ](../Webots/Setting-Up-Simulation-Webots-Advanced.html)
          * [ The Ros2Supervisor Node ](../Webots/Simulation-Supervisor.html)
          * [ Setting up a Reset Handler ](../Webots/Simulation-Reset-Handler.html)
        * [ Gazebo ](Simulation-Gazebo.html)
          * Setting up a robot simulation (Gazebo)
      * [ Security ](../../Security/Security-Main.html)
        * [ Setting up security ](../../Security/Introducing-ros2-security.html)
        * [ Understanding the security keystore ](../../Security/The-Keystore.html)
        * [ Ensuring security across machines ](../../Security/Security-on-Two.html)
        * [ Examining network traffic ](../../Security/Examine-Traffic.html)
        * [ Setting access controls ](../../Security/Access-Controls.html)
        * [ Deployment Guidelines ](../../Security/Deployment-Guidelines.html)
    * [ Demos ](../../../Demos.html)
      * [ Using quality-of-service settings for lossy networks ](../../../Demos/Quality-of-Service.html)
      * [ Managing nodes with managed lifecycles ](../../../Demos/Managed-Nodes.html)
      * [ Setting up efficient intra-process communication ](../../../Demos/Intra-Process-Communication.html)
      * [ Recording and playing back data with ` rosbag  ` using the ROS 1 bridge ](../../../Demos/Rosbag-with-ROS1-Bridge.html)
      * [ Understanding real-time programming ](../../../Demos/Real-Time-Programming.html)
      * [ Experimenting with a dummy robot ](../../../Demos/dummy-robot-demo.html)
      * [ Logging ](../../../Demos/Logging-and-logger-configuration.html)
      * [ Creating a content filtering subscription ](../../../Demos/Content-Filtering-Subscription.html)
    * [ Miscellaneous ](../../../Miscellaneous.html)
      * [ Deploying on IBM Cloud Kubernetes [community-contributed] ](../../../Miscellaneous/Deploying-ROS-2-on-IBM-Cloud.html)
      * [ Using Eclipse Oxygen with ` rviz2  ` [community-contributed] ](../../../Miscellaneous/Eclipse-Oxygen-with-ROS-2-and-rviz2.html)
      * [ Building a real-time Linux kernel [community-contributed] ](../../../Miscellaneous/Building-Realtime-rt_preempt-kernel-for-ROS-2.html)
      * [ Building a package with Eclipse 2021-06 ](../../../Miscellaneous/Building-ROS2-Package-with-eclipse-2021-06.html)
  * [ How-to Guides ](../../../../How-To-Guides.html)
    * [ Installation troubleshooting ](../../../../How-To-Guides/Installation-Troubleshooting.html)
    * [ Developing a ROS 2 package ](../../../../How-To-Guides/Developing-a-ROS-2-Package.html)
    * [ Documenting a ROS 2 package ](../../../../How-To-Guides/Documenting-a-ROS-2-Package.html)
    * [ ament_cmake user documentation ](../../../../How-To-Guides/Ament-CMake-Documentation.html)
    * [ ament_cmake_python user documentation ](../../../../How-To-Guides/Ament-CMake-Python-Documentation.html)
    * [ Migrating from ROS 1 to ROS 2 ](../../../../How-To-Guides/Migrating-from-ROS1.html)


![../../../../_images/add_lidar.png](../../../../_images/add_lidar.png)


Name


[ uuv_plume_msgs
](/uuvsimulator/uuv_plume_simulator/tree/master/uuv_plume_msgs
"uuv_plume_msgs")


[ .travis.yml ](/uuvsimulator/uuv_plume_simulator/blob/master/.travis.yml
".travis.yml")


#  Search code, repositories, users, issues, pull requests...


**Goal:** Launch a Simulation with Gazebo and ROS 2


  * [ Tutorials ](/tutorials)
  * [ Download ](/download)
  * [ Blog ](/blog.html)
  * [ Media ](/media)
  * [ Projects ](/projects)


##  [ Packages  0  ](/orgs/ros-simulation/packages?repo_name=gazebo_ros_pkgs)


[ README.md ](/ros-simulation/gazebo_ros_pkgs/blob/noetic-devel/README.md
"README.md")


##  About


    cd ~/catkin_ws
    catkin_make # or <catkin build>, if you are using catkin_tools
##  Example of usage
The plume simulator package are installed, one demonstration can be run to
visualize the plume particles in RViz. To start it, run

    roslaunch uuv_plume_simulator start_plume_example.launch

To start an example of a turbulent plume model, run the script

    roslaunch uuv_plume_simulator start_demo_turbulent_plume.launch

In this case, the plume runs independently from the [ UUV Simulator
](https://github.com/uuvsimulator/uuv_simulator) . In order to start this
example using one of the Gazebo worlds from UUV Simulator and therefore use
the current velocity topic generated by [ a Gazebo plugin
](https://github.com/uuvsimulator/uuv_simulator/blob/master/uuv_world_plugins/uuv_world_ros_plugins/include/uuv_world_ros_plugins/UnderwaterCurrentROSPlugin.hh)
, start the example first as

    roslaunch uuv_plume_simulator start_plume_example.launch use_gazebo:=true

and then

    roslaunch uuv_plume_simulator start_demo_turbulent_plume.launch use_gazebo:=true

If no current topic is available, the particles will accumulate around the
plume source.
To add a particle concentration sensor to the vehicle, check the URDF macro
snippets found [ here
](https://github.com/uuvsimulator/uuv_simulator/blob/master/uuv_sensor_plugins/uuv_sensor_plugins_ros/urdf/chemical_concentration.xacro)
that can be used to add one to the robot description.
##  License
` uuv_plume_simulator ` is open-sourced under the Apache-2.0 license. See the
[ LICENSE


> Link to the ` uuv_plume_simulator ` repository [ here
> ](https://github.com/uuvsimulator/uuv_plume_simulator)


[ **761** forks ](/ros-simulation/gazebo_ros_pkgs/forks)


[ .gitignore ](/uuvsimulator/uuv_plume_simulator/blob/master/.gitignore
".gitignore")


In Development


Cancel  Create saved search


Last commit message


#  Provide feedback


##  Tasks  ï


By Solution


* [ The ReadME Project  GitHub community articles  ](/readme)


#  ROS 2 integration overview


Gazebo is a stand-alone application which can be used independently of ROS or
ROS 2. The integration of Gazebo with either ROS version is done through a set
of packages called [ gazebo_ros_pkgs ](https://github.com/ros-
simulation/gazebo_ros_pkgs) . These packages provide a bridge between Gazebo's
C++ API and transport system, and ROS 2 messages and services.


|

View all files

##  Repository files navigation


###  3 Visualizing lidar data in ROS 2  ï


Several changes and refactoring were done to ` gazebo_ros_pkgs ` when
migrating from ROS 1 to ROS 2.


Go to file


##  [ Releases ](/uuvsimulator/uuv_plume_simulator/releases)


Releases


[ 6  tags  ](/uuvsimulator/uuv_plume_simulator/tags)


##  License


[ \+ 66 contributors ](/ros-simulation/gazebo_ros_pkgs/graphs/contributors)


There's no such requirement with ROS 2. Gazebo can be started without any
plugins and ROS-2-enabled plugins can be added at runtime.


](https://github.com/uuvsimulator/uuv_plume_simulator/blob/master/LICENSE)
file for details.
##  About
ROS nodes to generate a turbulent plume in an underwater environment
[ uuvsimulator.github.io/ ](https://uuvsimulator.github.io/
"https://uuvsimulator.github.io/")
###  Resources
Readme
###  License
Apache-2.0 license
[ Activity  ](/tiko5000/uuv_plume_simulator_ros2/activity)
###  Stars
[ **1** star ](/tiko5000/uuv_plume_simulator_ros2/stargazers)
###  Watchers
[ **0** watching ](/tiko5000/uuv_plume_simulator_ros2/watchers)
###  Forks
[ **1** fork ](/tiko5000/uuv_plume_simulator_ros2/forks)
[ Report repository ](/contact/report-
content?content_url=https%3A%2F%2Fgithub.com%2Ftiko5000%2Fuuv_plume_simulator_ros2&report=tiko5000+%28user%29)
##  [ Releases ](/tiko5000/uuv_plume_simulator_ros2/releases)
No releases published
##  [ Packages  0
](/users/tiko5000/packages?repo_name=uuv_plume_simulator_ros2)
No packages published
##  Languages
  * Python  78.5%
  * C++  18.4%
  * CMake  2.8%
  * Shell  0.3%
##  Footer
[ ](https://github.com "GitHub") © 2024 GitHub, Inc.
###  Footer navigation
  * [ Terms ](https://docs.github.com/site-policy/github-terms/github-terms-of-service)
  * [ Privacy ](https://docs.github.com/site-policy/privacy-policies/github-privacy-statement)
  * [ Security ](/security)
  * [ Status ](https://www.githubstatus.com/)
  * [ Docs ](https://docs.github.com/)
  * [ Contact ](https://support.github.com?tags=dotcom-footer)
  * Manage cookies
  * Do not share my personal information


Clear


[ uuv_plume_msgs
](/uuvsimulator/uuv_plume_simulator/tree/master/uuv_plume_msgs
"uuv_plume_msgs")


[ gazebo_ros_control ](/ros-simulation/gazebo_ros_pkgs/tree/noetic-
devel/gazebo_ros_control "gazebo_ros_control")


---|---|---|---

##  Latest commit
##  History
[ 128 Commits  ](/tiko5000/uuv_plume_simulator_ros2/commits/master/)
[ ](/tiko5000/uuv_plume_simulator_ros2/commits/master/)

###
[ images ](/tiko5000/uuv_plume_simulator_ros2/tree/master/images "images")
|
###
[ images ](/tiko5000/uuv_plume_simulator_ros2/tree/master/images "images")
|
|

###
[ uuv_cpc_sensor
](/tiko5000/uuv_plume_simulator_ros2/tree/master/uuv_cpc_sensor
"uuv_cpc_sensor")
|
###
[ uuv_cpc_sensor
](/tiko5000/uuv_plume_simulator_ros2/tree/master/uuv_cpc_sensor
"uuv_cpc_sensor")
|
|

###
[ uuv_plume_msgs
](/tiko5000/uuv_plume_simulator_ros2/tree/master/uuv_plume_msgs
"uuv_plume_msgs")
|
###
[ uuv_plume_msgs
](/tiko5000/uuv_plume_simulator_ros2/tree/master/uuv_plume_msgs
"uuv_plume_msgs")
|
|

###


Toggle navigation


[ gazebo_plugins ](/ros-simulation/gazebo_ros_pkgs/tree/noetic-
devel/gazebo_plugins "gazebo_plugins")


  * Take advantage of new ROS 2 features, such as masterless discovery.
  * Remove code which duplicates functionality already present in Gazebo.
  * Reduce duplication by standardizing common functionality, such as how to set ROS namespaces, parameters and topic remapping.
  * Modernize the codebase, making use of the latest SDFormat, Gazebo and Ignition APIs, as well as ROS 2's [ style guidelines ](https://github.com/ros2/ros2/wiki/Developer-Guide#c-1) and linters.
  * Add tests and demos for all ported functionality.


and then build your catkin workspace


First of all you should install ROS 2 and Gazebo. You have two options:


    * [ Collections ](/collections)
  * [ Pricing ](/pricing)
Search or jump to...
#  Search code, repositories, users, issues, pull requests...
Search
Clear
[ Search syntax tips ](https://docs.github.com/search-github/github-code-
search/understanding-github-code-search-syntax)
#  Provide feedback
We read every piece of feedback, and take your input very seriously.
Include my email address so I can be contacted
Cancel  Submit feedback
#  Saved searches
##  Use saved searches to filter your results more quickly
Name
Query
To see all available qualifiers, see our [ documentation
](https://docs.github.com/search-github/github-code-search/understanding-
github-code-search-syntax) .
Cancel  Create saved search
[ Sign in
](/login?return_to=https%3A%2F%2Fgithub.com%2Ftiko5000%2Fuuv_plume_simulator_ros2)
[ Sign up
](/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-
name%3E%2F%3Crepo-name%3E&source=header-
repo&source_repo=tiko5000%2Fuuv_plume_simulator_ros2)
You signed in with another tab or window. [ Reload ]() to refresh your
session.  You signed out in another tab or window. [ Reload ]() to refresh
your session.  You switched accounts on another tab or window. [ Reload ]() to
refresh your session.  Dismiss alert
{{ message }}
[ tiko5000 ](/tiko5000) /  **[ uuv_plume_simulator_ros2
](/tiko5000/uuv_plume_simulator_ros2) ** Public
forked from [ uuvsimulator/uuv_plume_simulator
](/uuvsimulator/uuv_plume_simulator)
  * [ Notifications ](/login?return_to=%2Ftiko5000%2Fuuv_plume_simulator_ros2)
  * [ Fork  1  ](/login?return_to=%2Ftiko5000%2Fuuv_plume_simulator_ros2)
  * [ Star  1  ](/login?return_to=%2Ftiko5000%2Fuuv_plume_simulator_ros2)
  *
ROS nodes to generate a turbulent plume in an underwater environment


###  Watchers


##  Prerequisites  ï


[ On gazebosim.org ](http://gazebosim.org/tutorials?cat=connect_ros)


    source /opt/ros/humble/setup.bash
    ros2 run ros_gz_bridge parameter_bridge /lidar2@sensor_msgs/msg/LaserScan[ignition.msgs.LaserScan --ros-args -r /lidar2:=/laser_scan


To see all available qualifiers, see our [ documentation
](https://docs.github.com/search-github/github-code-search/understanding-
github-code-search-syntax) .


Which should show:


You can’t perform that action at this time.


In this tutorial, you launched a robot simulation with Gazebo, launched
bridges with actuators and sensors, visualized data from a sensor, and moved a
diff drive robot.


[ Custom properties  ](/uuvsimulator/uuv_plume_simulator/custom-properties)


The ROS 1 integration required that Gazebo be launched with the `
gazebo_ros_api_plugin ` system plugin, which would initialize ROS.


Resources


Toggle navigation


For


In this demo you are going to simulate a simple diff drive robot in Gazebo.
You are going to use one of the worlds defined in the Gazebo examples called [
visualize_lidar.sdf ](https://github.com/gazebosim/gz-
sim/blob/main/examples/worlds/visualize_lidar.sdf) . To run this example you
should execute the following command in a terminal:


` uuv_plume_simulator ` is open-sourced under the Apache-2.0 license. See the
[ LICENSE
](https://github.com/uuvsimulator/uuv_plume_simulator/blob/master/LICENSE)
file for details.


To be able to communicate our simulation with ROS 2 you need to use a package
called ` ros_gz_bridge  ` . This package provides a network bridge which
enables the exchange of messages between ROS 2 and Gazebo Transport. You can
install this package by typing:


####  Table of Contents


##  Use saved searches to filter your results more quickly


[ wiki.ros.org/gazebo_ros_pkgs ](http://wiki.ros.org/gazebo_ros_pkgs
"http://wiki.ros.org/gazebo_ros_pkgs")


###  2 Configuring ROS 2  ï


###  1 Launch the simulation  ï


|
|

###
[ LICENSE ](/tiko5000/uuv_plume_simulator_ros2/blob/master/LICENSE "LICENSE")
|
###
[ LICENSE ](/tiko5000/uuv_plume_simulator_ros2/blob/master/LICENSE "LICENSE")
|
|

###
[ NOTICE ](/tiko5000/uuv_plume_simulator_ros2/blob/master/NOTICE "NOTICE")
|
###
[ NOTICE ](/tiko5000/uuv_plume_simulator_ros2/blob/master/NOTICE "NOTICE")
|
|

###
[ README.md ](/tiko5000/uuv_plume_simulator_ros2/blob/master/README.md
"README.md")
|
###
[ README.md ](/tiko5000/uuv_plume_simulator_ros2/blob/master/README.md
"README.md")
|
|

###
[ plume.png ](/tiko5000/uuv_plume_simulator_ros2/blob/master/plume.png
"plume.png")
|
###
[ plume.png ](/tiko5000/uuv_plume_simulator_ros2/blob/master/plume.png
"plume.png")
|
|

View all files


![../../../../_images/rviz2.png](../../../../_images/rviz2.png)


Search


Some goals of the refactoring were:


[ Sign in ](/login?return_to=https%3A%2F%2Fgithub.com%2Fros-
simulation%2Fgazebo_ros_pkgs)


Skip to content
Toggle navigation
[ ](https://github.com/)
[ Sign in
](/login?return_to=https%3A%2F%2Fgithub.com%2Ftiko5000%2Fuuv_plume_simulator_ros2)
  * Product
    * [ Actions  Automate any workflow  ](/features/actions)
    * [ Packages  Host and manage packages  ](/features/packages)
    * [ Security  Find and fix vulnerabilities  ](/features/security)
    * [ Codespaces  Instant dev environments  ](/features/codespaces)
    * [ Copilot  Write better code with AI  ](/features/copilot)
    * [ Code review  Manage code changes  ](/features/code-review)
    * [ Issues  Plan and track work  ](/features/issues)
    * [ Discussions  Collaborate outside of code  ](/features/discussions)
Explore
    * [ All features ](/features)
    * [ Documentation  ](https://docs.github.com)
    * [ GitHub Skills  ](https://skills.github.com/)
    * [ Blog  ](https://github.blog)
  * Solutions
For
    * [ Enterprise ](/enterprise)
    * [ Teams ](/team)
    * [ Startups ](/enterprise/startups)
    * [ Education  ](https://education.github.com)
By Solution
    * [ CI/CD & Automation ](/solutions/ci-cd/)
    * [ DevOps ](/solutions/devops/)
    * [ DevSecOps  ](https://resources.github.com/devops/fundamentals/devsecops/)
Resources
    * [ Learning Pathways  ](https://resources.github.com/learn/pathways/)
    * [ White papers, Ebooks, Webinars  ](https://resources.github.com/)
    * [ Customer Stories ](/customer-stories)
    * [ Partners  ](https://partner.github.com/)
  * Open Source
    * [ GitHub Sponsors  Fund open source developers  ](/sponsors)
    * [ The ReadME Project  GitHub community articles  ](/readme)
Repositories
    * [ Topics ](/topics)
    * [ Trending ](/trending)


roslaunch uuv_plume_simulator start_plume_example.launch


Readme


##  Repository files navigation
  * README
  * License
##  This is the ROS2 Port of the uuv_plume_simulator package.
It currently works with ROS2 Humble. Main Branch is compatible with Gazebo
Garden.
###  Current Status:
  * Particle Plume is working in ROS2
  * Ocean Current from Gazebo is considered in the simulation
    * Ocean Current is taken from the [ hydrodynamics plugin in Gazebo ](https://gazebosim.org/api/gazebo/6.9/classignition_1_1gazebo_1_1systems_1_1Hydrodynamics.html)
  * PointCloud2 Bridge to Gazebo
    * The PointCloud2 is published to the gz topic /particles2
###  HowTo.
Bridge the Topics:

    - ros_topic_name: "/ocean_current"
      gz_topic_name: "/ocean_current"
      ros_type_name: "geometry_msgs/msg/Point"
      gz_type_name: "gz.msgs.Vector3d"
      direction: GZ_TO_ROS

    - ros_topic_name: "/particles2"
      gz_topic_name: "/particles2"
      ros_type_name: "sensor_msgs/msg/PointCloud2"
      gz_type_name: "gz.msgs.PointCloudPacked"
      direction: ROS_TO_GZ

    - ros_topic_name: "/time_creation"
      gz_topic_name: "/time_creation"
      ros_type_name: "ros_gz_interfaces/msg/Float32Array"
      gz_type_name: "gz.msgs.Float_V"
      direction: ROS_TO_GZ

    - ros2 run ros_gz_bridge parameter_bridge /particles2@sensor_msgs/msg/PointCloud2@gz.msgs.PointCloudPacked /ocean_current@geometry_msgs/msg/Point@gz.msgs.Vector3d /time_creation@ros_gz_interfaces/msg/Float32Array@gz.msgs.Float_V

Start the particle plume


[ README.md ](/ros-simulation/gazebo_ros_pkgs/blob/noetic-devel/README.md
"README.md")


##  Requirements


[ README.md ](/uuvsimulator/uuv_plume_simulator/blob/master/README.md
"README.md")


[ ](/ros-simulation/gazebo_ros_pkgs/commits/noetic-devel/)

###


##  Summary  ï


[ uuvsimulator.github.io/ ](https://uuvsimulator.github.io/
"https://uuvsimulator.github.io/")
###  License
[ Apache-2.0 license ](/tiko5000/uuv_plume_simulator_ros2/blob/master/LICENSE)
[ 1  star ](/tiko5000/uuv_plume_simulator_ros2/stargazers) [ 18  forks
](/tiko5000/uuv_plume_simulator_ros2/forks) [ Branches
](/tiko5000/uuv_plume_simulator_ros2/branches) [ Tags
](/tiko5000/uuv_plume_simulator_ros2/tags) [ Activity
](/tiko5000/uuv_plume_simulator_ros2/activity)
[ Star  ](/login?return_to=%2Ftiko5000%2Fuuv_plume_simulator_ros2)
[ Notifications ](/login?return_to=%2Ftiko5000%2Fuuv_plume_simulator_ros2)
  * [ Code  ](/tiko5000/uuv_plume_simulator_ros2)
  * [ Pull requests  0  ](/tiko5000/uuv_plume_simulator_ros2/pulls)
  * [ Actions  ](/tiko5000/uuv_plume_simulator_ros2/actions)
  * [ Projects  0  ](/tiko5000/uuv_plume_simulator_ros2/projects)
  * [ Security  ](/tiko5000/uuv_plume_simulator_ros2/security)
  * [ Insights  ](/tiko5000/uuv_plume_simulator_ros2/pulse)
Additional navigation options
  * [ Code  ](/tiko5000/uuv_plume_simulator_ros2)
  * [ Pull requests  ](/tiko5000/uuv_plume_simulator_ros2/pulls)
  * [ Actions  ](/tiko5000/uuv_plume_simulator_ros2/actions)
  * [ Projects  ](/tiko5000/uuv_plume_simulator_ros2/projects)
  * [ Security  ](/tiko5000/uuv_plume_simulator_ros2/security)
  * [ Insights  ](/tiko5000/uuv_plume_simulator_ros2/pulse)
#  tiko5000/uuv_plume_simulator_ros2
This commit does not belong to any branch on this repository, and may belong
to a fork outside of the repository.
master
[ Branches  ](/tiko5000/uuv_plume_simulator_ros2/branches) [ Tags
](/tiko5000/uuv_plume_simulator_ros2/tags)
[ ](/tiko5000/uuv_plume_simulator_ros2/branches) [
](/tiko5000/uuv_plume_simulator_ros2/tags)
Go to file
Code
##  Folders and files
Name  |  Name  |
Last commit message
|
Last commit date


Go to file


Which should show:


[ .gitignore ](/ros-simulation/gazebo_ros_pkgs/blob/noetic-devel/.gitignore
".gitignore")


[ ](https://github.com/)


      * [ Beta 1 ( ` Asphalt  ` ) ](../../../../Releases/Beta1-Overview.html)
      * [ Alphas ](../../../../Releases/Alpha-Overview.html)
    * [ Development process for a release ](../../../../Releases/Release-Process.html)
  * [ Tutorials ](../../../../Tutorials.html)
    * [ Beginner: CLI tools ](../../../Beginner-CLI-Tools.html)
      * [ Configuring environment ](../../../Beginner-CLI-Tools/Configuring-ROS2-Environment.html)
      * [ Using ` turtlesim  ` , ` ros2  ` , and ` rqt  ` ](../../../Beginner-CLI-Tools/Introducing-Turtlesim/Introducing-Turtlesim.html)
      * [ Understanding nodes ](../../../Beginner-CLI-Tools/Understanding-ROS2-Nodes/Understanding-ROS2-Nodes.html)
      * [ Understanding topics ](../../../Beginner-CLI-Tools/Understanding-ROS2-Topics/Understanding-ROS2-Topics.html)
      * [ Understanding services ](../../../Beginner-CLI-Tools/Understanding-ROS2-Services/Understanding-ROS2-Services.html)
      * [ Understanding parameters ](../../../Beginner-CLI-Tools/Understanding-ROS2-Parameters/Understanding-ROS2-Parameters.html)
      * [ Understanding actions ](../../../Beginner-CLI-Tools/Understanding-ROS2-Actions/Understanding-ROS2-Actions.html)
      * [ Using ` rqt_console  ` to view logs ](../../../Beginner-CLI-Tools/Using-Rqt-Console/Using-Rqt-Console.html)
      * [ Launching nodes ](../../../Beginner-CLI-Tools/Launching-Multiple-Nodes/Launching-Multiple-Nodes.html)
      * [ Recording and playing back data ](../../../Beginner-CLI-Tools/Recording-And-Playing-Back-Data/Recording-And-Playing-Back-Data.html)
    * [ Beginner: Client libraries ](../../../Beginner-Client-Libraries.html)
      * [ Using ` colcon  ` to build packages ](../../../Beginner-Client-Libraries/Colcon-Tutorial.html)
      * [ Creating a workspace ](../../../Beginner-Client-Libraries/Creating-A-Workspace/Creating-A-Workspace.html)
      * [ Creating a package ](../../../Beginner-Client-Libraries/Creating-Your-First-ROS2-Package.html)
      * [ Writing a simple publisher and subscriber (C++) ](../../../Beginner-Client-Libraries/Writing-A-Simple-Cpp-Publisher-And-Subscriber.html)
      * [ Writing a simple publisher and subscriber (Python) ](../../../Beginner-Client-Libraries/Writing-A-Simple-Py-Publisher-And-Subscriber.html)
      * [ Writing a simple service and client (C++) ](../../../Beginner-Client-Libraries/Writing-A-Simple-Cpp-Service-And-Client.html)
      * [ Writing a simple service and client (Python) ](../../../Beginner-Client-Libraries/Writing-A-Simple-Py-Service-And-Client.html)
      * [ Creating custom msg and srv files ](../../../Beginner-Client-Libraries/Custom-ROS2-Interfaces.html)
      * [ Implementing custom interfaces ](../../../Beginner-Client-Libraries/Single-Package-Define-And-Use-Interface.html)
      * [ Using parameters in a class (C++) ](../../../Beginner-Client-Libraries/Using-Parameters-In-A-Class-CPP.html)
      * [ Using parameters in a class (Python) ](../../../Beginner-Client-Libraries/Using-Parameters-In-A-Class-Python.html)
      * [ Using ` ros2doctor  ` to identify issues ](../../../Beginner-Client-Libraries/Getting-Started-With-Ros2doctor.html)
      * [ Creating and using plugins (C++) ](../../../Beginner-Client-Libraries/Pluginlib.html)
    * [ Intermediate ](../../../Intermediate.html)
      * [ Managing Dependencies with rosdep ](../../../Intermediate/Rosdep.html)
      * [ Creating an action ](../../../Intermediate/Creating-an-Action.html)
      * [ Writing an action server and client (C++) ](../../../Intermediate/Writing-an-Action-Server-Client/Cpp.html)
      * [ Writing an action server and client (Python) ](../../../Intermediate/Writing-an-Action-Server-Client/Py.html)
      * [ Writing a Composable Node (C++) ](../../../Intermediate/Writing-a-Composable-Node.html)
      * [ Composing multiple nodes in a single process ](../../../Intermediate/Composition.html)
      * [ Monitoring for parameter changes (C++) ](../../../Intermediate/Monitoring-For-Parameter-Changes-CPP.html)
      * [ Launch ](../../../Intermediate/Launch/Launch-Main.html)
        * [ Creating a launch file ](../../../Intermediate/Launch/Creating-Launch-Files.html)
        * [ Integrating launch files into ROS 2 packages ](../../../Intermediate/Launch/Launch-system.html)


By Solution


[ NOTICE ](/uuvsimulator/uuv_plume_simulator/blob/master/NOTICE "NOTICE")


[ Notifications ](/login?return_to=%2Fuuvsimulator%2Fuuv_plume_simulator)


At this point you are ready to launch a bridge from ROS to Gazebo. In
particular you are going to create a bridge for the topic `
/model/vehicle_blue/cmd_vel  ` :


> Linux
>
>
>     sudo apt-get install ros-humble-teleop-twist-keyboard
>
>
> The default topic where ` teleop_twist_keyboard  ` is publishing Twist
> messages is ` /cmd_vel  ` but you can remap this topic to make use of the
> topic used in the bridge:
>
> Linux
>
>
>     source /opt/ros/humble/setup.bash
>     ros2 run teleop_twist_keyboard teleop_twist_keyboard --ros-args -r
> /cmd_vel:=/model/vehicle_blue/cmd_vel
>
>
> Which will show:
>
>
>     This node takes keypresses from the keyboard and publishes them
>     as Twist messages. It works best with a US keyboard layout.
>     ---------------------------
>     Moving around:
>        u    i    o
>        j    k    l
>        m    ,    .
>
>     For Holonomic mode (strafing), hold down the shift key:
>     ---------------------------
>        U    I    O
>        J    K    L
>        M    <    >
>
>     t : up (+z)
>     b : down (-z)
>
>     anything else : stop
>


Last commit date

---|---|---|---

##  Latest commit


[ **721** stars ](/ros-simulation/gazebo_ros_pkgs/stargazers)


Built with [ Sphinx ](https://www.sphinx-doc.org/) using a [ theme
](https://github.com/readthedocs/sphinx_rtd_theme) provided by [ Read the Docs
](https://readthedocs.org) .


roslaunch uuv_plume_simulator start_demo_turbulent_plume.launch use_gazebo:=true


ign gazebo -v 4 -r visualize_lidar.sdf


###  Topics


    * [ Actions  Automate any workflow  ](/features/actions)
    * [ Packages  Host and manage packages  ](/features/packages)
    * [ Security  Find and fix vulnerabilities  ](/features/security)
    * [ Codespaces  Instant dev environments  ](/features/codespaces)
    * [ Copilot  Write better code with AI  ](/features/copilot)
    * [ Code review  Manage code changes  ](/features/code-review)
    * [ Issues  Plan and track work  ](/features/issues)
    * [ Discussions  Collaborate outside of code  ](/features/discussions)


#  Setting up a robot simulation (Gazebo)  ï


Apache-2.0 license


    * [ All features ](/features)
    * [ Documentation  ](https://docs.github.com)
    * [ GitHub Skills  ](https://skills.github.com/)
    * [ Blog  ](https://github.blog)


  * [ Code  ](/uuvsimulator/uuv_plume_simulator)
  * [ Issues  ](/uuvsimulator/uuv_plume_simulator/issues)
  * [ Pull requests  ](/uuvsimulator/uuv_plume_simulator/pulls)
  * [ Actions  ](/uuvsimulator/uuv_plume_simulator/actions)
  * [ Projects  ](/uuvsimulator/uuv_plume_simulator/projects)
  * [ Security  ](/uuvsimulator/uuv_plume_simulator/security)
  * [ Insights  ](/uuvsimulator/uuv_plume_simulator/pulse)


[ .travis.yml ](/uuvsimulator/uuv_plume_simulator/blob/master/.travis.yml
".travis.yml")


[ gazebo_ros_pkgs ](/ros-simulation/gazebo_ros_pkgs/tree/noetic-
devel/gazebo_ros_pkgs "gazebo_ros_pkgs")


    * [ Topics ](/topics)
    * [ Trending ](/trending)
    * [ Collections ](/collections)


* [ The ReadME Project  GitHub community articles  ](/readme)


[ ](https://github.com "GitHub") © 2024 GitHub, Inc.


##  [ Releases ](/ros-simulation/gazebo_ros_pkgs/releases)


[ CONTRIBUTING.md ](/ros-simulation/gazebo_ros_pkgs/blob/noetic-
devel/CONTRIBUTING.md "CONTRIBUTING.md")


* Summary


In ROS 2, this plugin is being split into smaller, more focused plugins. You
can read the migration details on [ ROS 2 Migration: gazebo_ros_api_plugin
](https://github.com/ros-
simulation/gazebo_ros_pkgs/wiki/ROS-2-Migration:-gazebo_ros_api_plugin) .


Then you need to configure the ` fixed  frame  ` :


[ gazebo_dev ](/ros-simulation/gazebo_ros_pkgs/tree/noetic-devel/gazebo_dev
"gazebo_dev")


[ ros ](/topics/ros "Topic: ros") [ gazebo ](/topics/gazebo "Topic: gazebo") [
rov ](/topics/rov "Topic: rov") [ underwater-robotics ](/topics/underwater-
robotics "Topic: underwater-robotics") [ auv ](/topics/auv "Topic: auv") [
plume ](/topics/plume "Topic: plume") [ uuv ](/topics/uuv "Topic: uuv") [ uuv-
simulator ](/topics/uuv-simulator "Topic: uuv-simulator")