    01450                     model_state->model_name.c_str(),model_state->reference_frame.c_str());
    01451           return;
    01452         }
    01453
    01454         bool is_paused = gazebo::Simulator::Instance()->IsPaused();
    01455         gazebo::Simulator::Instance()->SetPaused(true);
    01456         model->SetWorldPose(target_pose);
    01457         gazebo::Simulator::Instance()->SetPaused(is_paused);
    01458
    01459         // set model velocity to 0
    01460         model->SetLinearVel(target_pos_dot);
    01461         model->SetAngularVel(target_rot_dot);
    01462
    01463         return;
    01464       }
    01465     }
    01466
    [01469](classGazeboROSNode.html#af9745546aff989b97db487fd056a6437)     bool [applyJointEffort](classGazeboROSNode.html#af9745546aff989b97db487fd056a6437)([gazebo_msgs::ApplyJointEffort::Request](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyJointEffortRequest__.html) &req,[gazebo_msgs::ApplyJointEffort::Response](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyJointEffortResponse__.html) &res)
    01470     {
    01471       gazebo::Joint* joint = NULL;
    01472       const std::vector<gazebo::Model*> models = gazebo::World::Instance()->GetModels();
    01473       for (std::vector<gazebo::Model*>::const_iterator miter = models.begin(); miter != models.end(); miter++)
    01474       {
    01475         joint = (*miter)->GetJoint(req.[joint_name](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyJointEffortRequest__.html#a52984f9468e6d9a8a653539a51a0a169));
    01476         if (joint) break;
    01477       }
    01478
    01479       if (joint == NULL)
    01480       {
    01481         res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyJointEffortResponse__.html#a4fe78ed7323ef413512b16b9f3f9a9bf) = false;
    01482         res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyJointEffortResponse__.html#a7b23717c14f723390bb7e8d243f5f481) = "ApplyJointEffort: joint not found";
    01483         return false;
    01484       }
    01485       else
    01486       {
    01487
    01488         [GazeboROSNode::ForceJointJob](classGazeboROSNode_1_1ForceJointJob.html)* fjj = new [GazeboROSNode::ForceJointJob](classGazeboROSNode_1_1ForceJointJob.html);
    01489         fjj->[joint](classGazeboROSNode_1_1ForceJointJob.html#ae6b3a1f76030167a49587d20a9745f22) = joint;
    01490         fjj->[force](classGazeboROSNode_1_1ForceJointJob.html#a12a44288945997636725a0d3917a783b) = req.[effort](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyJointEffortRequest__.html#a6dfb37382256882568c810ffbb66ca1c);
    01491         fjj->[start_time](classGazeboROSNode_1_1ForceJointJob.html#a1a6abca9e598c0860f79c9f86a440cde) = req.[start_time](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyJointEffortRequest__.html#a932cec6676221a8cf64d9b6d21495ee3);


[ ](javascript:; "Share Article") [
](//www.rssing.com/contact.php?r=o6&u=%2F%2Fgazebo214.rssing.com%2Fchan-57893035%2Flatest-
article10-live.php "Article Support")


This is undefined behavior; use Layout.alignment instead. [GUI] [Wrn]
[Application.cc:797] [QT]
file::/EntityContextMenuPlugin/EntityContextMenuPlugin.qml:67:3: QML
EntityContextMenu: Detected anchors on an item that is managed by a layout.
This is undefined behavior; use Layout.alignment instead. [GUI] [Msg] Added
plugin [Entity Context Menu] to main window [GUI] [Msg] Loaded plugin
[EntityContextMenuPlugin] from path [/usr/lib/x86_64-linux-gnu/ign-
gazebo-6/plugins/gui/libEntityContextMenuPlugin.so] [GUI] [Dbg]
[Application.cc:426] Loading plugin [GzSceneManager] [GUI] [Msg] Added plugin
[Scene Manager] to main window [GUI] [Msg] Loaded plugin [GzSceneManager] from
path [/usr/lib/x86_64-linux-gnu/ign-gazebo-6/plugins/gui/libGzSceneManager.so]
[GUI] [Dbg] [Application.cc:426] Loading plugin [InteractiveViewControl] [GUI]
[Msg] Camera view controller topic advertised on [/gui/camera/view_control]
[GUI] [Msg] Added plugin [Interactive view control] to main window [GUI] [Msg]
Loaded plugin [InteractiveViewControl] from path [/usr/lib/x86_64-linux-
gnu/ign-gui-6/plugins/libInteractiveViewControl.so] [GUI] [Dbg]
[Application.cc:426] Loading plugin [CameraTracking] [GUI] [Msg] Added plugin
[Camera tracking] to main window [GUI] [Msg] Loaded plugin [CameraTracking]
from path [/usr/lib/x86_64-linux-gnu/ign-gui-6/plugins/libCameraTracking.so]
[GUI] [Dbg] [Application.cc:426] Loading plugin [MarkerManager] [GUI] [Msg]
Listening to stats on [/world/default/stats] [GUI] [Msg] Added plugin [Marker
Manager] to main window [GUI] [Msg] Loaded plugin [MarkerManager] from path
[/usr/lib/x86_64-linux-gnu/ign-gui-6/plugins/libMarkerManager.so] [GUI] [Dbg]
[Application.cc:426] Loading plugin [SelectEntities] [GUI] [Msg] Added plugin
[Select entities] to main window [GUI] [Msg] Loaded plugin [SelectEntities]
from path [/usr/lib/x86_64-linux-gnu/ign-
gazebo-6/plugins/gui/libSelectEntities.so] [GUI] [Dbg] [Application.cc:426]
Loading plugin [Spawn] [GUI] [Wrn] [Application.cc:797] [QT]
file::/Spawn/Spawn.qml:32:3: QML Connections: Implicitly defined onFoo
properties in Connections are deprecated. Use this syntax instead: function
onFoo(  ) { ... } [GUI] [Msg] Added plugin [Spawn] to main window [GUI] [Msg]
Loaded plugin [Spawn] from path [/usr/lib/x86_64-linux-gnu/ign-
gazebo-6/plugins/gui/libSpawn.so] [GUI] [Dbg] [Application.cc:426] Loading
plugin [VisualizationCapabilities] [GUI] [Msg] View as transparent service on
[/gui/view/transparent] [GUI] [Msg] View as wireframes service on
[/gui/view/wireframes] [GUI] [Msg] View center of mass service on
[/gui/view/com] [GUI] [Msg] View inertia service on [/gui/view/inertia] [GUI]
[Msg] View collisions service on [/gui/view/collisions] [GUI] [Msg] View
joints service on [/gui/view/joints] [GUI] [Msg] View frames service on
[/gui/view/frames] [GUI] [Msg] Added plugin [Visualization capabilities] to


April 14, 2024, 8:14 am


` [ 2e3841e
](/k-okada/gazebo_ros_pkgs/commit/2e3841eb274c3fd8ca4fdb243490625a74677d20) `


  * [ Home  ](//www.rssing.com/index.php)
    * [ About Us ](//www.rssing.com/about.php)
    * [ Catalog ](//www.rssing.com/catalog.php)
  * [ Search  ](//www.rssing.com/search.php)
  * [ Register RSS  ](//www.rssing.com/register.php)
  * [ Embed RSS  ](//www.rssing.com/embed.php)
    * [ FAQ ](//www.rssing.com/embed.php?a=whe)
    * [ Get Embed Code ](//www.rssing.com/embed.php)
    * [ Example: Default CSS ](//www.rssing.com/embed.php?a=ex1)
    * [ Example: Custom CSS ](//www.rssing.com/embed.php?a=ex2)
    * [ Example: Custom CSS per Embedding ](//www.rssing.com/embed.php?a=ex3)
  * [ Super RSS  ](//www.rssing.com/super.php)
    * [ Usage ](//www.rssing.com/super.php)
    * [ View Latest ](//www.rssing.com/super.php?a=l)
    * [ Create ](//www.rssing.com/super.php?a=crt)


#  [ Spawning multiple models causes error
](//gazebo214.rssing.com/chan-57893035/latest-article30-live.php)


Copy link


Sorry, something went wrong.


Viewing latest articles


Now test to see if your new Gazebo Model Database is properly configured by
launching Gazebo:


Can you confirm it's still broken?
thanks.

---

All reactions


#  [ HOW TO CREATE QR CODE IN GAZEBO11
](//gazebo214.rssing.com/chan-57893035/latest-article20-live.php)


What is the procedure to add a custom model to a .world file (using Gazebo
Fortress)? I installed Gazebo Fortress on Ubuntu 22.04 using the Fortress
binary at https://gazebosim.org/docs. I also have ROS2 Humble installed. I've
tried this for example:  model://fire_truck  ..using a model downloaded from
https://github.com/osrf/gazebo_models/tree/master/fire_truck. But, I get an
error that the file cannot be found. After installation, neither
GZ_SIM_RESOURCE_PATH or IGN_GAZEBO_RESOURCE_PATH are set. I tried setting
those to [my package path]/models, but that's a no go. The docs seem to be all
over the place on this issue and none of the demos have a local file for a uri
as an example. I also tried using the same format to include a vehicle model
in /opt/ros/humble/share/ros_gz_sim_demos/models/ which contains the vehicle
model.sdf and model.config files. Also, if it matters, I not only had to
install Fortress (binary) but the Garden binary because without Garden, the gz
command could not be found.


###  "ROS Service Call" Robot Spawn Method


temporary hack to **fix** the -J joint position option \(issue #93\), sleeping
for 1 second to avoid race condition. this branch should only be used for
debugging, merge only as a last resort.") [ #279 ](https://github.com/ros-
simulation/gazebo_ros_pkgs/pull/279) [ from k-okada/93_hydro ](/ros-
simulation/gazebo_ros_pkgs/commit/838241a5806120e17d08b2b79d89264c5aa44a0e
"Merge pull request #279 from k-okada/93_hydro


John


[ Search ](javascript:;)


[ ](javascript:; "Share Article") [
](//www.rssing.com/contact.php?r=o6&u=%2F%2Fgazebo214.rssing.com%2Fchan-57893035%2Flatest-
article17-live.php "Article Support")


[ ↂ
](////drama1031.rssing.com/chan-27446141/article21.html#c27446141a21i856785604
"Za Pakhtoon Yum: A mind-altering foray into Pukhtun life and culture")


[ _≫_ Next: Spawning multiple models causes error
](//gazebo214.rssing.com/chan-57893035/latest.php#c57893035a6954 "Next
Article")


[ ](//www.rssing.com/index.php?zw=2123 "Home") [ $ ](javascript:; "MoMoney")


Is there any update to this? Pause/Unpause approach does not work on
Gazebo9/Kinetic.

---

All reactions


[ ](javascript:; "Ouch") 0


##  Comments


Copy link


[ segmentation fault core dumped with ROS Melodic, Gazebo 9  #1041  ](/ros-
simulation/gazebo_ros_pkgs/issues/1041)


* 👍  5 reactions


None yet


Given a Gazebo world, is there a way to generate a 3D occupancy map? I want a
3D matrix of 0s/1s so that I can use it for path planning algorithms.


    02040                    reference_force.y,
    02041                    reference_force.z,
    02042                    reference_torque.x,
    02043                    reference_torque.y,
    02044                    reference_torque.z,
    02045                    body->GetName().c_str(),
    02046                    target_force.x,
    02047                    target_force.y,
    02048                    target_force.z,
    02049                    target_torque.x,
    02050                    target_torque.y,
    02051                    target_torque.z
    02052                  );
    02053
    02054       }
    02055       else if (req.[reference_frame](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a478aa71d79dc3b29ba87496996406980) == "" || req.[reference_frame](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a478aa71d79dc3b29ba87496996406980) == "world" || req.[reference_frame](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a478aa71d79dc3b29ba87496996406980) == "map" || req.[reference_frame](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a478aa71d79dc3b29ba87496996406980) == "/map")
    02056       {
    02057         [ROS_INFO](../../../api/rosconsole/html/macros__generated_8h.html#a20d5da22f16df09d52a7577227636a83)("ApplyBodyWrench: reference_frame is empty/world/map, using inertial frame, transferring from body relative to inertial frame");
    02058         // FIXME: transfer to inertial frame
    02059         gazebo::Pose3d target_to_reference = body->GetWorldPose();
    02060         target_force = reference_force;
    02061         target_torque = reference_torque;
    02062
    02063       }
    02064       else
    02065       {
    02066         [ROS_ERROR](../../../api/rosconsole/html/macros__generated_8h.html#a7fb635b03cc608284eadecd2f8becd9a)("ApplyBodyWrench: reference_frame is not a valid link name");
    02067         res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchResponse__.html#a614b4dd49b7b7f87fb360bc0f420f8ed) = false;
    02068         res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchResponse__.html#aeb381da235043f2b7e2875d78beacade) = "ApplyBodyWrench: reference_frame not found";
    02069         return false;
    02070       }
    02071
    02072       // apply wrench
    02073       // schedule a job to do below at appropriate times:
    02074       // body->SetForce(force)
    02075       // body->SetTorque(torque)
    02076       [GazeboROSNode::WrenchBodyJob](classGazeboROSNode_1_1WrenchBodyJob.html)* wej = new [GazeboROSNode::WrenchBodyJob](classGazeboROSNode_1_1WrenchBodyJob.html);
    02077       wej->[body](classGazeboROSNode_1_1WrenchBodyJob.html#aff58f515a5c987724b2bfb53956cb18f) = body;
    02078       wej->[force](classGazeboROSNode_1_1WrenchBodyJob.html#a9abb6606ca8e3c79350e68be69d1dc67) = target_force;
    02079       wej->[torque](classGazeboROSNode_1_1WrenchBodyJob.html#a37e9b921287c703e53f2017823c2b6ed) = target_torque;


Collaborator


July 29, 2023, 1:56 am


#  [ Tricycle drive plugin: Impossible to control linear and angular speed at
the same time ](//gazebo214.rssing.com/chan-57893035/latest-article4-live.php)


    01952         // set body velocity to desired twist
    01953         body->SetLinearVel(target_linear_vel);
    01954         body->SetAngularVel(target_angular_vel);
    01955
    01956       }
    01957
    01958     }
    01959
    01960
    [01964](classGazeboROSNode.html#ab198eaed8eab1ba85cdfdfb72c268150)     void [transformWrench](classGazeboROSNode.html#ab198eaed8eab1ba85cdfdfb72c268150 "shift wrench from reference frame to target frame assume wrench is defined in")( gazebo::Vector3 &target_force, gazebo::Vector3 &target_torque,
    01965                                gazebo::Vector3 reference_force, gazebo::Vector3 reference_torque,
    01966                                gazebo::Pose3d target_to_reference )
    01967     {
    01968       // rotate force into target frame
    01969       target_force = target_to_reference.rot.RotateVector(reference_force);
    01970       // rotate torque into target frame
    01971       target_torque = target_to_reference.rot.RotateVector(reference_torque);
    01972
    01973       // target force is the refence force rotated by the target->reference transform
    01974       target_force = target_force;
    01975       target_torque = target_torque + target_to_reference.pos.GetCrossProd(target_force);
    01976     }
    01977
    [01980](classGazeboROSNode.html#affc8ea4611f0cd8c4b4a497056359398)     bool [applyBodyWrench](classGazeboROSNode.html#affc8ea4611f0cd8c4b4a497056359398)([gazebo_msgs::ApplyBodyWrench::Request](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html) &req,[gazebo_msgs::ApplyBodyWrench::Response](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchResponse__.html) &res)
    01981     {
    01982       gazebo::Body* body = dynamic_cast<gazebo::Body*>(gazebo::World::Instance()->GetEntityByName(req.[body_name](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a5ac16bd4c0d1004ab321e7f93b603e95)));
    01983       gazebo::Body* frame = dynamic_cast<gazebo::Body*>(gazebo::World::Instance()->GetEntityByName(req.[reference_frame](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a478aa71d79dc3b29ba87496996406980)));
    01984
    01985       if (!body)
    01986       {
    01987         [ROS_ERROR](../../../api/rosconsole/html/macros__generated_8h.html#a7fb635b03cc608284eadecd2f8becd9a)("ApplyBodyWrench: body [%s] does not exist",req.[body_name](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a5ac16bd4c0d1004ab321e7f93b603e95).c_str());
    01988         res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchResponse__.html#a614b4dd49b7b7f87fb360bc0f420f8ed) = false;
    01989         res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchResponse__.html#aeb381da235043f2b7e2875d78beacade) = "ApplyBodyWrench: body does not exist";
    01990         return false;
    01991       }
    01992
    01993       // target wrench
    01994       gazebo::Vector3 reference_force(req.[wrench](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a9a96ff63f003a8df06b91cdccd26f4c6).[force](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Wrench__.html#a2922f100d999404b660018eb809c6a20).[x](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Vector3__.html#abf9dabaf651196aee50fd14bf3b643be),req.[wrench](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a9a96ff63f003a8df06b91cdccd26f4c6).[force](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Wrench__.html#a2922f100d999404b660018eb809c6a20).[y](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Vector3__.html#aaea58ad929c43960a06f728d97132404),req.[wrench](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a9a96ff63f003a8df06b91cdccd26f4c6).[force](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Wrench__.html#a2922f100d999404b660018eb809c6a20).[z](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Vector3__.html#a4cde719326e6c3688ab50b51ab4708b1));
    01995       gazebo::Vector3 reference_torque(req.[wrench](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a9a96ff63f003a8df06b91cdccd26f4c6).[torque](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Wrench__.html#a9fa00191ad94ce694feaf9bbc510043f).[x](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Vector3__.html#abf9dabaf651196aee50fd14bf3b643be),req.[wrench](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a9a96ff63f003a8df06b91cdccd26f4c6).[torque](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Wrench__.html#a9fa00191ad94ce694feaf9bbc510043f).[y](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Vector3__.html#aaea58ad929c43960a06f728d97132404),req.[wrench](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a9a96ff63f003a8df06b91cdccd26f4c6).[torque](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Wrench__.html#a9fa00191ad94ce694feaf9bbc510043f).[z](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Vector3__.html#a4cde719326e6c3688ab50b51ab4708b1));
    01996       gazebo::Vector3 reference_point(req.[reference_point](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a4efb2891cc9a840bb1791fe0bd2bcf2d).[x](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Point__.html#acd9420e6916084b2a9c09019bfda1708),req.[reference_point](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a4efb2891cc9a840bb1791fe0bd2bcf2d).[y](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Point__.html#a46a84ff5a3e5817ab5693abda66fccb0),req.[reference_point](../../gazebo_msgs/html/structgazebo__msgs_1_1ApplyBodyWrenchRequest__.html#a4efb2891cc9a840bb1791fe0bd2bcf2d).[z](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Point__.html#a061f0093e927a95998f35ceceb5cebda));


[ _≫_ Next: How to simulate a "Vaccum" or a suction action?
](//gazebo214.rssing.com/chan-57893035/latest.php#c57893035a6941 "Next
Article")


HI there. I am trying to implement Gazebo simulation for space environment
using International Space Station(ISS) urdf model. I wants to ISS urdf model
apply zero gravity but it doesn`t work. Can I know my two questions? 1\. Can I
applying zero gravity for ISS urdf model? If that can`t, should I convert
.urdf to .sdf? 2\. Is there anyone who have experienced implementation about
space environment using Gazebo?? Please let me know my questions, and any
leave replies. I am looking forward to your comments and feedbacks. best
regards


[ ](javascript:; "Share Article") [
](//www.rssing.com/contact.php?r=o6&u=%2F%2Fgazebo214.rssing.com%2Fchan-57893035%2Flatest-
article18-live.php "Article Support")


  while (!g_shouldExit)
  {
    std::this_thread::sleep_for(std::chrono::milliseconds(20));
    // Check if server and gui are still open, if they are closed
    // close this process as well
    serverClosed = server.try_get_exit_status(serverExitCode);
    clientClosed = client.try_get_exit_status(clientExitCode);
    if (serverClosed || clientClosed)
    {
      g_shouldExit = true;
    }
  }
  // Cleanup
  serverClosed = server.try_get_exit_status(serverExitCode);
  if (!serverClosed)
  {
    server.kill();
  }
  clientClosed = client.try_get_exit_status(clientExitCode);
  if (!clientClosed)
  {
    client.kill();
  }
  // Get exit status
  serverExitCode = server.get_exit_status();
  clientExitCode = client.get_exit_status();
  int exitCode = 0;
  if (serverExitCode != 0 || clientExitCode != 0)
  {
    exitCode = 1;
  }
  return exitCode;
}
#endif


Labels


![Wicked Cool Toys Announces 'The Loud House' Plush Toy Line | NYTF 2018
\[Updated\]](//3.bp.blogspot.com/-nOI76eg4gOE/W5arvkqxY5I/AAAAAAAA-
bs/dk80jyd1o5ICOU25r8SLjyKQySQQUb0lACLcBGAs/s400/The-Loud-House-Wicked-Cool-
Toys-Booth-Toy-Nickelodeon-Nick-TFNY-NYTF_1.jpg)


[ ![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)


[ _≫_ Next: Gazebo garden : Plugin for FOV distortion model
](//gazebo214.rssing.com/chan-57893035/latest.php#c57893035a6947 "Next
Article")


I experienced this issue with ROS Kinetic and Gazebo 7 (ros-kinetic-desktop-
full version).


i spent a lot of time investigating this today to no avail


please give [ gazebo branch set_joint_position_on spawn (c8d353e)
](https://bitbucket.org/osrf/gazebo/commits/c8d353ea1c1348aa900f38d821b8bca2f1953c31)
a try? thanks.

---

All reactions


[ Search ](javascript:;)


My bad. Pause/Unpause method actually works on Gazebo9/Kinetic environment

---

All reactions


It appears to me that it also depends on the point in time at which the
controllers are started...?

---

All reactions


[ _≪_ Previous: Close-loop kinematics in URDF and SDF
](//gazebo214.rssing.com/chan-57893035/latest.php#c57893035a6940 "Previous
Article")


####  XACRO Example with PR2


No branches or pull requests


[ _≪_ Previous: Gazebo sim code concepts
](//gazebo214.rssing.com/chan-57893035/latest.php#c57893035a6946 "Previous
Article")


* 👍  2 reactions


![Duas for Difficulties, Ism Adham-'Allah’s Greatest Name' and Secrets of Ya
Hayyu Ya
Qayyum](//2.bp.blogspot.com/-IJM3qg4P1NQ/Ugc0BBcHquI/AAAAAAAAAVc/XjnDYEvefA8/s400/Istighfar+al-
Kabir.jpg)


Hmm, the branch seems to work for the test you added.
However, testing it with the universal_robot [ test-branch
](https://github.com/ipa-fxm/universal_robot/tree/test_initial_joint_position)
running
` roslaunch ur_gazebo ur5.launch `
doesn't seem to work...maybe there is something more when having transmission
in the urdf and controllers running...

---

All reactions


[ Sign up
](/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-
name%3E%2F%3Crepo-
name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-
repo&source_repo=ros-simulation%2Fgazebo_ros_pkgs)


August 7, 2023, 4:41 pm


August 2, 2023, 1:44 am


Contributor


  * [ Code  ](/ros-simulation/gazebo_ros_pkgs)
  * [ Issues  ](/ros-simulation/gazebo_ros_pkgs/issues)
  * [ Pull requests  ](/ros-simulation/gazebo_ros_pkgs/pulls)
  * [ Actions  ](/ros-simulation/gazebo_ros_pkgs/actions)
  * [ Projects  ](/ros-simulation/gazebo_ros_pkgs/projects)
  * [ Wiki  ](/ros-simulation/gazebo_ros_pkgs/wiki)
  * [ Security  ](/ros-simulation/gazebo_ros_pkgs/security)
  * [ Insights  ](/ros-simulation/gazebo_ros_pkgs/pulse)


Jump to bottom


  * Title: Gazebo: Q&A Forum - RSS feed
  * Channel Number: 57893035
  * Language: English
  * Registered On: November 26, 2015, 5:48 pm
  * Number of Articles: 6955
  * Latest Snapshot: August 11, 2023, 2:58 am
  * RSS URL: [ http://answers.gazebosim.org/feeds/rss ](javascript:;)
  * Publisher: [ http://answers.gazebosim.org/questions/ ](javascript:;)
  * Description: Open source question and answer forum for Gazebo
  * Catalog: [ //gazebo214.rssing.com/catalog.php?indx=57893035 ](//gazebo214.rssing.com/catalog.php?indx=57893035)


[ ](javascript:; "Share Chan")


[ ](javascript:; "Like") 0


Copy link


I'm using the debian version 1.9.5 compatible with ROS hydro. Is there any
workaround? Like Dave, I'm just trying to set the initial joint position
directly (during roslaunch).

---

All reactions


Repositories


Title:


April 9, 2024, 4:00 pm


[ @ironmig ](https://github.com/ironmig) I had issues as long as nothing else
way hogging the CPU, if you don't have this issue without stress test then you
won't have it with stress either. My ROS installation Kinetic and Gazebo 9.

---

All reactions


#  [ Close-loop kinematics in URDF and SDF
](//gazebo214.rssing.com/chan-57893035/latest-article15-live.php)


July 7, 2014, 2:06 pm


**debug**


Occurs on very large model (hexapod) for both paused and unpaused starts.


[ davetcoleman ](/davetcoleman) opened this issue  Jul 30, 2013  · 85 comments


April 8, 2024, 8:41 am


service on [/gui/screenshot] [GUI] [Msg] Added plugin [Screenshot] to main
window [GUI] [Msg] Loaded plugin [Screenshot] from path
[/usr/lib/x86_64-linux-gnu/ign-gui-6/plugins/libScreenshot.so] [GUI] [Dbg]
[Application.cc:426] Loading plugin [CopyPaste] [GUI] [Msg] Added plugin
[Copy/Paste] to main window [GUI] [Msg] Loaded plugin [CopyPaste] from path
[/usr/lib/x86_64-linux-gnu/ign-gazebo-6/plugins/gui/libCopyPaste.so] [GUI]
[Dbg] [Application.cc:426] Loading plugin [ComponentInspector] [GUI] [Msg]
Added plugin [Component inspector] to main window [GUI] [Msg] Loaded plugin
[ComponentInspector] from path [/usr/lib/x86_64-linux-gnu/ign-
gazebo-6/plugins/gui/libComponentInspector.so] [GUI] [Dbg]
[Application.cc:426] Loading plugin [EntityTree] [GUI] [Wrn]
[Application.cc:797] [QT] file::/EntityTree/EntityTree.qml:148:7: QML
ToolButton: Detected anchors on an item that is managed by a layout. This is
undefined behavior; use Layout.alignment instead. [GUI] [Msg] Added plugin
[Entity tree] to main window [GUI] [Msg] Loaded plugin [EntityTree] from path
[/usr/lib/x86_64-linux-gnu/ign-gazebo-6/plugins/gui/libEntityTree.so] [GUI]
[Dbg] [Application.cc:296] Loading window config [GUI] [Msg] Using server
control service [/server_control] [GUI] [Dbg] [Application.cc:569] Applying
config [GUI] [Wrn] [Application.cc:797] [QT]
file::/EntityTree/EntityTree.qml:148:7: QML ToolButton: Detected anchors on an
item that is managed by a layout. This is undefined behavior; use
Layout.alignment instead. [GUI] [Wrn] [Application.cc:797] [QT]
file::/WorldStats/WorldStats.qml:53:3: QML RowLayout: Binding loop detected
for property "x" [GUI] [Wrn] [Application.cc:797] [QT]
file::/EntityContextMenuPlugin/EntityContextMenuPlugin.qml:52:3: QML
RenderWindowOverlay: Detected anchors on an item that is managed by a layout.
This is undefined behavior; use Layout.alignment instead. [GUI] [Wrn]
[Application.cc:797] [QT]
file::/EntityContextMenuPlugin/EntityContextMenuPlugin.qml:67:3: QML
EntityContextMenu: Detected anchors on an item that is managed by a layout.
This is undefined behavior; use Layout.alignment instead. [GUI] [Msg] Loading
plugin [ignition-rendering-ogre2] [GUI] [Dbg] [MinimalScene.cc:560] Create
scene [scene] [Msg] Found no publishers on /stats, adding root stats topic
[Msg] Found no publishers on /clock, adding root clock topic [Dbg]
[SimulationRunner.cc:491] Creating PostUpdate worker threads: 2 [Dbg]
[SimulationRunner.cc:502] Creating postupdate worker thread (0) [GUI] [Msg]
Loading plugin [ignition-rendering-ogre2] [GUI] [Dbg]
[TransformControl.cc:528] TransformControl plugin is using camera
[scene::Camera(65527)] [GUI] [Msg] Loading plugin [ignition-rendering-ogre2]
[GUI] [Msg] Loading plugin [ignition-rendering-ogre2] [GUI] [Dbg]


RSSing.com


[ ![Highlights - Bringing young people to the forefront of EU policy making
-...](//www.europarl.europa.eu/resources/library/images/20200115PHT70307/20200115PHT70307-ms.jpg)
](////europees185.rssing.com/chan-78228109/article559.html#c78228109a559i1335926349)


    02617   }
    02618   catch (gazebo::GazeboError e)
    02619   {
    02620     std::cerr << "Main simulation loop failed" << std::endl;
    02621     std::cerr << e << std::endl;
    02622     gazebo::Simulator::Instance()->Fini();
    02623     ros::shutdown();
    02624     return -1;
    02625   }
    02626
    02627   // Finalization and clean up
    02628   try
    02629   {
    02630     gazebo::Simulator::Instance()->Fini();
    02631   }
    02632   catch (gazebo::GazeboError e)
    02633   {
    02634     std::cerr << "Finalization failed" << std::endl;
    02635     std::cerr << e << std::endl;
    02636     ros::shutdown();
    02637     return -1;
    02638   }
    02639
    02640   printf("Done.\n");
    02641   ros::shutdown();
    02642   return 0;
    02643 }


[ _≪_ Previous: Ground truth map for a gazebo world like the willowgarage
model ](//gazebo214.rssing.com/chan-57893035/latest.php#c57893035a6953
"Previous Article")


[ ![@dpsolomon](https://avatars.githubusercontent.com/u/4515469?s=80&v=4)
](/dpsolomon)


Labels


**[ hsu ](/hsu) ** commented  Aug 31, 2014


Sorry, something went wrong.


  * [ Main Page  ](index.html)
  * [ Related Pages  ](pages.html)
  * [ Namespaces  ](namespaces.html)
  * [ Classes  ](annotated.html)
  * [ Files  ](files.html)
  * ![](search/search.png) [ ![](search/close.png) ](javascript:searchBox.CloseResultsWindow\(\))


` [ temporary hack to **fix** the -J joint position option (issue ](/jhu-lcsr-
forks/gazebo_ros_pkgs/commit/db0587cfca8003e218eee8540f34dbfc9eab9ca9
"temporary hack to **fix** the -J joint position option \(issue #93\),
sleeping for 1 second to avoid race condition. this branch should only be used
for debugging, merge only as a last resort.") [ ros-sim…
](https://github.com/ros-simulation/gazebo_ros_pkgs/issues/93) ` …


###  [ Class 10 Sanskrit Grammar Book Solutions अपठित-अवबोधनम्
](////learn4804.rssing.com/chan-65098560/article5043.html#c65098560a5043i329832300)


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


**[ sccashma ](/sccashma) ** commented  Apr 17, 2021


Closed


**[ hsu ](/hsu) ** commented  Sep 23, 2014


Its still broken with Baxter using a URDF, but your SDF version does work on
my computer using the double pendulum example. To reproduce, first get the
Baxter URDF:


    // remove server from foreground process group
    setpgid(0, 0);
    execvp(argvServer[0], argvServer);
  }
  delete[] argvServer;
  delete[] argvClient;
  return returnValue;
}
#else
std::atomic<bool> g_shouldExit = false;
void sig_handler(int /*signo*/)
{
  g_shouldExit = true;
}
int main(int _argc, char **_argv)
{
  if (_argc >= 2 &&
      (strcmp(_argv[1], "-h") == 0 || strcmp(_argv[1], "--help") == 0)) {
    help();
    return 0;
  }
  signal(SIGINT, sig_handler);
  std::vector<std::string> argvServer;
  std::vector<std::string> argvClient;
  argvServer.push_back("gzserver");
  argvClient.push_back("gzclient");
  for (int i = 1; i < _argc; ++i)
  {
    argvServer.push_back(std::string(_argv[i]));
    argvClient.push_back(std::string(_argv[i]));
  }
  // Start server
  TinyProcessLib::Process server(argvServer);
  // Start client
  TinyProcessLib::Process client(argvClient);
  // Wait
  bool serverClosed = false;
  bool clientClosed = false;
  int serverExitCode = 0;
  int clientExitCode = 0;


** 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)


[ ](javascript:; "Share Article") [
](//www.rssing.com/contact.php?r=o6&u=%2F%2Fgazebo214.rssing.com%2Fchan-57893035%2Flatest-
article23-live.php "Article Support")


[ _≫_ Next: Start actor trajectory from plugin
](//gazebo214.rssing.com/chan-57893035/latest.php#c57893035a6944 "Next
Article")


July 23, 2023, 10:05 am


/*
 * Copyright (C) 2012 Open Source Robotics Foundation
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *
*/
#ifndef _WIN32
#include <sys/wait.h>
#include <unistd.h>
#include <signal.h>
#include <sys/types.h>
#else
#include <process.hpp>
#include <signal.h>
#endif
#include "gazebo/common/Console.hh"
#include "gazebo/Server.hh"
#include "gazebo/gui/GuiIface.hh"
/////////////////////////////////////////////////
void help()
{
  std::cerr << "gazebo -- Run the Gazebo server and GUI.\n\n";
  std::cerr << "`gazebo` [options] <world_file>\n\n";
  std::cerr << "Gazebo server runs simulation and handles commandline "
    << "options, starts a Master, runs World update and sensor generation "
    << "loops. This also starts the Gazebo GUI client in a separate "
    << "process.\n\n";
  std::cerr << "Options:\n"
  << "  -v [ --version ]              Output version information.\n"
  << "  --verbose                     Increase the messages written to the "


[ ![@sccashma](https://avatars.githubusercontent.com/u/39361797?s=80&v=4)
](/sccashma)


[ Copy Share URL ](javascript:;)


#  gazeboros.cpp


Sorry, something went wrong.


[ _≪_ Previous: Create voxel map from a gazebo world
](//gazebo214.rssing.com/chan-57893035/latest.php#c57893035a6932 "Previous
Article")


Copy link


###  [ Meet Peter Nygard Girlfriends & Children
](////dailyentertainmentnews33.rssing.com/chan-41166720/article94.html#c41166720a94i1969999888)


**[ hsu ](/hsu) ** commented  Sep 17, 2014


` [ 4c33ec9
](/k-okada/gazebo_ros_pkgs/commit/4c33ec95e7fee2bce024ca0f5317bb6913ebdf0b) `


[ _≫_ Next: Create voxel map from a gazebo world
](//gazebo214.rssing.com/chan-57893035/latest.php#c57893035a6932 "Next
Article")


AFAIK it was never fixed

---

All reactions


[ ](javascript:; "Like") 0


**[ musamarcusso ](/musamarcusso) ** commented  Aug 29, 2019


[ ](//www.rssing.com/index.php?zw=2123 "Home") [ $ ](javascript:; "MoMoney")


####  Latest Images


I want to create a plugin that publishes the contact forces a specific link
experiences along a particular local axis to a specific topic in order to
simulate something similar to a pressure sensor. My idea was to collect all
current collisions the particular link is in, sum up all the forces and
project it onto the particular local axis. However, I already struggle to get
the desired contact information. I started by creating a plugin that inherits
from the following three interfaces: public ISystemConfigure public
ISystemPreUpdate public ISystemPostUpdate Where I then go on to load all the
required sdf parameters in the `Configure` function and check for time leaps
in the `PreUpdate`. I'm also able to create and publish dummy force messages
in the `PostUpdate` function, however, I can't seem to figure out how to
access the true contact forces the link is experiencing. The function is
defined as: void PostUpdate(const UpdateInfo &_info, const
EntityComponentManager &_ecm) I.e., I somehow have access to the contact
information via the `ecm`. Ideally, there'd be something like std::vector
gz::physics::GetLinkContactsById(ecm.GetIDByName(link_name)) So what would be
the *best practice* to get the contact information within the `PostUpdate`
step? Are there any examples that are doing this already? Thanks


Collaborator


April 11, 2024, 5:27 pm


©2014 Open Source Robotics Foundation


[
![@anshulpaigwar](https://avatars.githubusercontent.com/u/6399885?s=80&u=4d67f9d0f1f8be52a1989f831716cf4fde3cbbba&v=4)
](/anshulpaigwar)


Hello, Is there a way to generate a Voxel map of a Gazebo world without using
mapping algorithms & robotic sensors?


I figured out the issue, in order for -J command to work we need to launch the
Gazebo simulation paused so that physics is off. Then use ` -unpause ` flag
with the spawner to turn on the physics.


April 8, 2024, 1:08 pm


[ ![@hsu](https://avatars.githubusercontent.com/u/138109?s=80&v=4) ](/hsu)


Sorry, something went wrong.


      <?xml version="1.0"?>
      <model>
        <name>MYROBOT</name>
        <version>1.0</version>
        <sdf>urdf/MYROBOT.urdf</sdf>
        <author>
          <name>My name</name>
          <email>name@email.address</email>
        </author>
        <description>
          A description of the model
        </description>
      </model>


![Frequency
Adverbs](//busyteacher.org/uploads/posts/2014-04/thumbs/1396577766_adverbs-of-
frecuency-0.png)


I made the following observations when trying to use ` -J ` arguments with `
spawn_model ` :
(Setup: Trusty, Indigo, gazebo 2.2.3-1~trusty, gazebo_ros_pkgs/indigo-devel
from source)


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


    01067       }
    01068
    01069       if (joint == NULL)
    01070       {
    01071         res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1GetJointPropertiesResponse__.html#a2a2cb7c7066864032464d6d3890f5c0f) = false;
    01072         res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1GetJointPropertiesResponse__.html#aa80b144f5800e4e20b38b3038421cbb6) = "GetJointProperties: joint not found";
    01073         return false;
    01074       }
    01075       else
    01076       {
    01078         res.[type](../../gazebo_msgs/html/structgazebo__msgs_1_1GetJointPropertiesResponse__.html#aa9c32ade868063a405bbcf701bc3779c) = res.[REVOLUTE](../../gazebo_msgs/html/structgazebo__msgs_1_1GetJointPropertiesResponse__.html#a3814fc0db2c495ae60a37d2fb1718af2a2af1b26c6ab433260380799e9e0573ea);
    01079
    01080         res.[damping](../../gazebo_msgs/html/structgazebo__msgs_1_1GetJointPropertiesResponse__.html#a490206645d989b4eaad69d0a8857e00d).clear(); // to be added to gazebo
    01081         //res.damping.push_back(joint->GetDamping(0));
    01082
    01083         res.[position](../../gazebo_msgs/html/structgazebo__msgs_1_1GetJointPropertiesResponse__.html#a5f5955ffefdab37df5d555602256f5e3).clear(); // use GetAngle(i)
    01084         res.[position](../../gazebo_msgs/html/structgazebo__msgs_1_1GetJointPropertiesResponse__.html#a5f5955ffefdab37df5d555602256f5e3).push_back(joint->GetAngle(0).GetAsRadian());
    01085
    01086         res.[rate](../../gazebo_msgs/html/structgazebo__msgs_1_1GetJointPropertiesResponse__.html#a92c113a01fbc7d8a1a5836371da4b76b).clear(); // use GetVelocity(i)
    01087         res.[rate](../../gazebo_msgs/html/structgazebo__msgs_1_1GetJointPropertiesResponse__.html#a92c113a01fbc7d8a1a5836371da4b76b).push_back(joint->GetVelocity(0));
    01088
    01089         res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1GetJointPropertiesResponse__.html#a2a2cb7c7066864032464d6d3890f5c0f) = true;
    01090         res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1GetJointPropertiesResponse__.html#aa80b144f5800e4e20b38b3038421cbb6) = "GetJointProperties: got properties";
    01091         return true;
    01092       }
    01093     }
    01094
    [01097](classGazeboROSNode.html#a0b81cc4d3c13b3b3e3feee801e4caa48)     bool [getLinkProperties](classGazeboROSNode.html#a0b81cc4d3c13b3b3e3feee801e4caa48)([gazebo_msgs::GetLinkProperties::Request](../../gazebo_msgs/html/structgazebo__msgs_1_1GetLinkPropertiesRequest__.html) &req,[gazebo_msgs::GetLinkProperties::Response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetLinkPropertiesResponse__.html) &res)
    01098     {
    01099       gazebo::Body* body = dynamic_cast<gazebo::Body*>(gazebo::World::Instance()->GetEntityByName(req.[link_name](../../gazebo_msgs/html/structgazebo__msgs_1_1GetLinkPropertiesRequest__.html#a093856e39c205b34f00e66d37027632a)));
    01100       if (body == NULL)
    01101       {
    01102         res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1GetLinkPropertiesResponse__.html#a84ce8f4df675b6924cfa52a366663e5f) = false;
    01103         res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1GetLinkPropertiesResponse__.html#a70abfa0b58777c634a35301a549dcc0e) = "GetLinkProperties: link not found, did you forget to scope the link by model name?";
    01104         return false;
    01105       }
    01106       else
    01107       {
    01109         res.[gravity_mode](../../gazebo_msgs/html/structgazebo__msgs_1_1GetLinkPropertiesResponse__.html#a119c48f090b86491907f33fd051b1ceb) = body->GetGravityMode();
    01110


##  Using ` roslaunch ` to Open World Models


Remember that the command ` catkin_create_pkg ` is used for creating new
packages, though this can also easily be adapted for rosbuild if you must.
Most of these folders and files should be self explanatory.


Open


I have not yet investigated further what causes this behavior, but I wanted to
document this here!
Can someone confirm this observations?
Any thoughts?

---

👍  1  littleggghost reacted with thumbs up emoji  ❤  3  littleggghost,
Robotawi, and juandpenan reacted with heart emoji


#  spawn_model -J initial joint positions not working  #93


sudo apt-get install ros-jade-pr2-common


The test file in the ` gazebo_ros_pkgs/issue_93_set_joint_position ` branch
works fine!


    02285       else
    02286         return false;
    02287     }
    02288
    [02290](classGazeboROSNode.html#a6939d75364517afe1057ad97edf8bef6)     gazebo::Joint* [getJointByName](classGazeboROSNode.html#a6939d75364517afe1057ad97edf8bef6 "get joint by name")(std::string joint_name)
    02291     {
    02292       // look through all models in the world, search for body name that matches frameName
    02293       std::vector<gazebo::Model*> all_models = gazebo::World::Instance()->GetModels();
    02294       for (std::vector<gazebo::Model*>::iterator miter = all_models.begin(); miter != all_models.end(); miter++)
    02295       {
    02296         if ((*miter) && (*miter)->GetJoint(joint_name))
    02297           return (*miter)->GetJoint(joint_name);
    02298       }
    02299       return NULL;
    02300     }
    02301
    02302
    [02303](classGazeboROSNode_1_1WrenchBodyJob.html)     class [WrenchBodyJob](classGazeboROSNode_1_1WrenchBodyJob.html)
    02304     {
    02305       public:
    [02306](classGazeboROSNode_1_1WrenchBodyJob.html#aff58f515a5c987724b2bfb53956cb18f)         gazebo::Body* [body](classGazeboROSNode_1_1WrenchBodyJob.html#aff58f515a5c987724b2bfb53956cb18f);
    [02307](classGazeboROSNode_1_1WrenchBodyJob.html#a9abb6606ca8e3c79350e68be69d1dc67)         gazebo::Vector3 [force](classGazeboROSNode_1_1WrenchBodyJob.html#a9abb6606ca8e3c79350e68be69d1dc67);
    [02308](classGazeboROSNode_1_1WrenchBodyJob.html#a37e9b921287c703e53f2017823c2b6ed)         gazebo::Vector3 [torque](classGazeboROSNode_1_1WrenchBodyJob.html#a37e9b921287c703e53f2017823c2b6ed);
    [02309](classGazeboROSNode_1_1WrenchBodyJob.html#a801ad39110b8f202470bd1562a62bd02)         [ros::Time](../../../api/rostime/html/classros_1_1Time.html) [start_time](classGazeboROSNode_1_1WrenchBodyJob.html#a801ad39110b8f202470bd1562a62bd02);
    [02310](classGazeboROSNode_1_1WrenchBodyJob.html#a4e8f3e2d041e97817a80a6feb9bd25a6)         [ros::Duration](../../../api/rostime/html/classros_1_1Duration.html) [duration](classGazeboROSNode_1_1WrenchBodyJob.html#a4e8f3e2d041e97817a80a6feb9bd25a6);
    02311     };
    02312
    [02313](classGazeboROSNode_1_1ForceJointJob.html)     class [ForceJointJob](classGazeboROSNode_1_1ForceJointJob.html)
    02314     {
    02315       public:
    [02316](classGazeboROSNode_1_1ForceJointJob.html#ae6b3a1f76030167a49587d20a9745f22)         gazebo::Joint* [joint](classGazeboROSNode_1_1ForceJointJob.html#ae6b3a1f76030167a49587d20a9745f22);
    [02317](classGazeboROSNode_1_1ForceJointJob.html#a12a44288945997636725a0d3917a783b)         double [force](classGazeboROSNode_1_1ForceJointJob.html#a12a44288945997636725a0d3917a783b); // should this be a array?
    [02318](classGazeboROSNode_1_1ForceJointJob.html#a1a6abca9e598c0860f79c9f86a440cde)         [ros::Time](../../../api/rostime/html/classros_1_1Time.html) [start_time](classGazeboROSNode_1_1ForceJointJob.html#a1a6abca9e598c0860f79c9f86a440cde);
    [02319](classGazeboROSNode_1_1ForceJointJob.html#abb80ad252fc707d94ab89aeb4dc93a72)         [ros::Duration](../../../api/rostime/html/classros_1_1Duration.html) [duration](classGazeboROSNode_1_1ForceJointJob.html#abb80ad252fc707d94ab89aeb4dc93a72);
    02320     };
    02321
    [02322](classGazeboROSNode.html#ade2831b1970d2ceed871e82a9140c2bb)     std::vector<GazeboROSNode::WrenchBodyJob*> [wrench_body_jobs](classGazeboROSNode.html#ade2831b1970d2ceed871e82a9140c2bb);
    [02323](classGazeboROSNode.html#a22ab41eec754d289d8c56f05045f480e)     std::vector<GazeboROSNode::ForceJointJob*> [force_joint_jobs](classGazeboROSNode.html#a22ab41eec754d289d8c56f05045f480e);
    02324
    [02325](classGazeboROSNode.html#a10111db7cc35bc709eb1dd9f8ac6673d)     double [lastWrenchBodyUpdateTime](classGazeboROSNode.html#a10111db7cc35bc709eb1dd9f8ac6673d);


` [ add test for issue ](/ros-
simulation/gazebo_ros_pkgs/commit/ef848cb8265f7c76fc201a0d69cb387c11b0436c
"add test for issue #93, set joint position on spawn_model") [ #93
](https://github.com/ros-simulation/gazebo_ros_pkgs/issues/93) [ , set joint
position on spawn_model ](/ros-
simulation/gazebo_ros_pkgs/commit/ef848cb8265f7c76fc201a0d69cb387c11b0436c
"add test for issue #93, set joint position on spawn_model") `


[ k-okada ](/k-okada) pushed a commit to k-okada/gazebo_ros_pkgs that
referenced this issue  Nov 27, 2014


[GUI] [Dbg] [Application.cc:426] Loading plugin [MarkerManager] [GUI] [Msg]
Listening to stats on [/world/default/stats] [GUI] [Msg] Added plugin [Marker
Manager] to main window [GUI] [Msg] Loaded plugin [MarkerManager] from path
[/usr/lib/x86_64-linux-gnu/ign-gui-6/plugins/libMarkerManager.so] [GUI] [Dbg]
[Application.cc:426] Loading plugin [SelectEntities] [GUI] [Msg] Added plugin
[Select entities] to main window [GUI] [Msg] Loaded plugin [SelectEntities]
from path [/usr/lib/x86_64-linux-gnu/ign-
gazebo-6/plugins/gui/libSelectEntities.so] [GUI] [Dbg] [Application.cc:426]
Loading plugin [Spawn] [GUI] [Wrn] [Application.cc:797] [QT]
file::/Spawn/Spawn.qml:32:3: QML Connections: Implicitly defined onFoo
properties in Connections are deprecated. Use this syntax instead: function
onFoo(  ) { ... } [GUI] [Msg] Added plugin [Spawn] to main window [GUI] [Msg]
Loaded plugin [Spawn] from path [/usr/lib/x86_64-linux-gnu/ign-
gazebo-6/plugins/gui/libSpawn.so] [GUI] [Dbg] [Application.cc:426] Loading
plugin [VisualizationCapabilities] [GUI] [Msg] View as transparent service on
[/gui/view/transparent] [GUI] [Msg] View as wireframes service on
[/gui/view/wireframes] [GUI] [Msg] View center of mass service on
[/gui/view/com] [GUI] [Msg] View inertia service on [/gui/view/inertia] [GUI]
[Msg] View collisions service on [/gui/view/collisions] [GUI] [Msg] View
joints service on [/gui/view/joints] [GUI] [Msg] View frames service on
[/gui/view/frames] [GUI] [Msg] Added plugin [Visualization capabilities] to
main window [GUI] [Msg] Loaded plugin [VisualizationCapabilities] from path
[/usr/lib/x86_64-linux-gnu/ign-
gazebo-6/plugins/gui/libVisualizationCapabilities.so] [GUI] [Dbg]
[Application.cc:426] Loading plugin [WorldControl] [GUI] [Wrn]
[Application.cc:797] [QT] file::/WorldControl/WorldControl.qml:30:3: QML
Connections: Implicitly defined onFoo properties in Connections are
deprecated. Use this syntax instead: function onFoo(  ) { ... } [GUI] [Msg]
Using world control service [/world/default/control] [GUI] [Msg] Listening to
stats on [/world/default/stats] [GUI] [Dbg] [WorldControl.cc:246] Using an
event to share WorldControl msgs with the server [GUI] [Msg] Added plugin
[World control] to main window [GUI] [Msg] Loaded plugin [WorldControl] from
path [/usr/lib/x86_64-linux-gnu/ign-gui-6/plugins/libWorldControl.so] [GUI]
[Dbg] [Application.cc:426] Loading plugin [WorldStats] [GUI] [Msg] Listening
to stats on [/world/default/stats] [GUI] [Msg] Added plugin [World stats] to
main window [GUI] [Msg] Loaded plugin [WorldStats] from path
[/usr/lib/x86_64-linux-gnu/ign-gui-6/plugins/libWorldStats.so] [GUI] [Dbg]
[Application.cc:426] Loading plugin [Shapes] [GUI] [Msg] Added plugin [Shapes]
to main window [GUI] [Msg] Loaded plugin [Shapes] from path
[/usr/lib/x86_64-linux-gnu/ign-gazebo-6/plugins/gui/libShapes.so] [GUI] [Dbg]


* [ GitHub Sponsors  Fund open source developers  ](/sponsors)


[ ![People's Blog • Germany Bans the Number
44](//thepeoplescube.com/red/download/file.php?id=57239&sid=5e19e13fd670da65c8b6b496c0630b51)
](////political6769.rssing.com/chan-78425830/article66.html#c78425830a66i1994484930)


…leeping for 1 second to avoid race condition. this branch should only be used for debugging, merge only as a last resort.


[ ](//www.rssing.com/index.php?zw=2123 "Home") [ $ ](javascript:; "MoMoney")


RSSing.com


temporary hack to **fix** the -J joint position option (issue [#93](https://github.com/ros-simulation/gazebo_ros_pkgs/issues/93)), sleeping for 1 second to avoid race condition. this branch should only be used for debugging, merge only as a last resort.


[ ](javascript:; "Share Article") [
](//www.rssing.com/contact.php?r=o6&u=%2F%2Fgazebo214.rssing.com%2Fchan-57893035%2Flatest-
article12-live.php "Article Support")


> I take back the namespace comment. Still, was there ever a solution to
>  this?
>
> —
>  Reply to this email directly or view it on GitHub
>  [ #93 (comment) ](https://github.com/ros-
> simulation/gazebo_ros_pkgs/issues/93#issuecomment-51569115)
>  .

---

All reactions


[ ](javascript:; "Ouch") 0


I'm testing on setting baxter gazebo simulation using baxter_gazebo.install of
indigo-devel of gazebo_simulator package on indigo.

---

All reactions


Search


Sorry, something went wrong.


Copy link


[ ↂ
](////murder540.rssing.com/chan-6412619/article1.html#c6412619a1i1155785771
"Murder in Australia: 2010")


**[ the-raspberry-pi-guy ](/the-raspberry-pi-guy) ** commented  Apr 18, 2021


[
![@rcywongaa](https://avatars.githubusercontent.com/u/7285669?s=40&u=f519c42eb9805998e455ed5c15cafce90fb2d638&v=4)
](/rcywongaa) [ rcywongaa ](/rcywongaa) mentioned this issue  Sep 7, 2022


##  Exporting model paths from a package.xml


#  [ How to get colliding entities with gpu_lidar sensor (ray)
](//gazebo214.rssing.com/chan-57893035/latest-article24-live.php)


  sig_killed = true;
  kill_one_process(pid2, "client", 5.0, killed2, status2);
  kill_one_process(pid1, "server", 5.0, killed1, status1);
}
/////////////////////////////////////////////////
int main(int _argc, char **_argv)
{
  if (_argc >= 2 &&
      (strcmp(_argv[1], "-h") == 0 || strcmp(_argv[1], "--help") == 0))
  {
    help();
    return 0;
  }
  struct sigaction sigact;
  sigact.sa_flags = 0;
  sigact.sa_handler = sig_handler;
  if (sigemptyset(&sigact.sa_mask) != 0)
    std::cerr << "sigemptyset failed while setting up for SIGINT" << std::endl;
  if (sigaction(SIGINT, &sigact, NULL))
  {
    std::cerr << "Stopping. Unable to catch SIGINT.\n"
              << " Please visit http://gazebosim.org/support.html for help.\n";
    return 0;
  }
  // The following was added in
  // https://osrf-migration.github.io/gazebo-gh-pages/#!/osrf/gazebo/pull-requests/2923,
  // but it is causing shutdown issues when gazebo is used with ros.
  // if (sigaction(SIGTERM, &sigact, NULL))
  // {
  //   std::cerr << "Stopping. Unable to catch SIGTERM.\n";
  //   return 0;
  // }
  pid1 = fork();
  char **argvServer = new char*[_argc+1];
  char **argvClient = new char*[_argc+1];
  argvServer[0] = const_cast<char*>("gzserver");
  argvClient[0] = const_cast<char*>("gzclient");
  for (int i = 1; i < _argc; ++i)
  {
    argvServer[i] = _argv[i];


Open


**[ the-raspberry-pi-guy ](/the-raspberry-pi-guy) ** commented  Feb 19, 2021


    01280       // stuff only works in ODE right now
    01281       res.[ode_config](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsPropertiesResponse__.html#ac462f68d51f1728d1dd2785ad9205542).[auto_disable_bodies](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEPhysics__.html#af4555ca9c1ede8b07fc50cd2a2008f65) = gazebo::World::Instance()->GetPhysicsEngine()->GetAutoDisableFlag();
    01282       res.[ode_config](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsPropertiesResponse__.html#ac462f68d51f1728d1dd2785ad9205542).[sor_pgs_precon_iters](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEPhysics__.html#a3c1b3fedf2a622faaec46676570eb3bc) = gazebo::World::Instance()->GetPhysicsEngine()->GetSORPGSPreconIters();
    01283       res.[ode_config](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsPropertiesResponse__.html#ac462f68d51f1728d1dd2785ad9205542).[sor_pgs_iters](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEPhysics__.html#a0426be3e2cd9c192b511f0f6c2fe8f52) = gazebo::World::Instance()->GetPhysicsEngine()->GetSORPGSIters();
    01284       res.[ode_config](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsPropertiesResponse__.html#ac462f68d51f1728d1dd2785ad9205542).[sor_pgs_rms_error_tol](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEPhysics__.html#afc440eb7f5da3792d00114fb3edf1edc) = gazebo::World::Instance()->GetPhysicsEngine()->GetRMSErrorTolerance();
    01285       res.[ode_config](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsPropertiesResponse__.html#ac462f68d51f1728d1dd2785ad9205542).[sor_pgs_w](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEPhysics__.html#a217a5bc35754775e2e27be8fce736fed) = gazebo::World::Instance()->GetPhysicsEngine()->GetSORPGSW();
    01286       res.[ode_config](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsPropertiesResponse__.html#ac462f68d51f1728d1dd2785ad9205542).[contact_surface_layer](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEPhysics__.html#a37d70bee50b3f628b6b7271c9792d6b5) = gazebo::World::Instance()->GetPhysicsEngine()->GetContactSurfaceLayer();
    01287       res.[ode_config](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsPropertiesResponse__.html#ac462f68d51f1728d1dd2785ad9205542).[contact_max_correcting_vel](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEPhysics__.html#af0c9a9a7e12ab8d902fb1930497b156d) = gazebo::World::Instance()->GetPhysicsEngine()->GetContactMaxCorrectingVel();
    01288       res.[ode_config](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsPropertiesResponse__.html#ac462f68d51f1728d1dd2785ad9205542).[cfm](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEPhysics__.html#abd023dd5214874a3dc73ff35db1676e3) = gazebo::World::Instance()->GetPhysicsEngine()->GetWorldCFM();
    01289       res.[ode_config](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsPropertiesResponse__.html#ac462f68d51f1728d1dd2785ad9205542).[erp](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEPhysics__.html#a229fd2dd48856e64045104fab4caf707) = gazebo::World::Instance()->GetPhysicsEngine()->GetWorldERP();
    01290       res.[ode_config](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsPropertiesResponse__.html#ac462f68d51f1728d1dd2785ad9205542).[max_contacts](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEPhysics__.html#a6e9643a7c7db7222eb0eb8d54d29473e) = gazebo::World::Instance()->GetPhysicsEngine()->GetMaxContacts();
    01291
    01292       res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsPropertiesResponse__.html#aa7e7302e0e30fb4e0aa16f081d21f14e) = true;
    01293       res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsPropertiesResponse__.html#a0e6808f37adb340db2fdcdf72a39c77c) = "GetPhysicsProperties: got properties";
    01294       return true;
    01295     }
    01296
    [01299](classGazeboROSNode.html#a95acae858b94081270cfe0bf737ebe3e)     bool [setJointProperties](classGazeboROSNode.html#a95acae858b94081270cfe0bf737ebe3e)([gazebo_msgs::SetJointProperties::Request](../../gazebo_msgs/html/structgazebo__msgs_1_1SetJointPropertiesRequest__.html) &req,[gazebo_msgs::SetJointProperties::Response](../../gazebo_msgs/html/structgazebo__msgs_1_1SetJointPropertiesResponse__.html) &res)
    01300     {
    01304       gazebo::Joint* joint = NULL;
    01305       const std::vector<gazebo::Model*> models = gazebo::World::Instance()->GetModels();
    01306       for (std::vector<gazebo::Model*>::const_iterator miter = models.begin(); miter != models.end(); miter++)
    01307       {
    01308         joint = (*miter)->GetJoint(req.[joint_name](../../gazebo_msgs/html/structgazebo__msgs_1_1SetJointPropertiesRequest__.html#a5a2e3d8206c200250d9dbd502d373c3e));
    01309         if (joint) break;
    01310       }
    01311
    01312       if (joint == NULL)
    01313       {
    01314         res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1SetJointPropertiesResponse__.html#a096c5a5c26c0786b03971c3f9ec2b895) = false;
    01315         res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1SetJointPropertiesResponse__.html#a49f3349c2fc084eb75ed189b49d8da9d) = "SetJointProperties: joint not found";
    01316         return false;
    01317       }
    01318       else
    01319       {
    01320         for(unsigned int [i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392)=0;[i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392)< req.[ode_joint_config](../../gazebo_msgs/html/structgazebo__msgs_1_1SetJointPropertiesRequest__.html#a46c6f9d85a9286f37692778a3aacd393).[damping](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEJointProperties__.html#ab0382d947d974e1a55d9e10eae1f3520).size();[i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392)++)
    01321           joint->SetDamping([i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392),req.[ode_joint_config](../../gazebo_msgs/html/structgazebo__msgs_1_1SetJointPropertiesRequest__.html#a46c6f9d85a9286f37692778a3aacd393).[damping](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEJointProperties__.html#ab0382d947d974e1a55d9e10eae1f3520)[[i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392)]);
    01322         for(unsigned int [i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392)=0;[i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392)< req.[ode_joint_config](../../gazebo_msgs/html/structgazebo__msgs_1_1SetJointPropertiesRequest__.html#a46c6f9d85a9286f37692778a3aacd393).[hiStop](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEJointProperties__.html#a3aca5a03f65a3709d121d5e51dde73e8).size();[i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392)++)
    01323           joint->SetAttribute(gazebo::Joint::HI_STOP,[i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392),req.[ode_joint_config](../../gazebo_msgs/html/structgazebo__msgs_1_1SetJointPropertiesRequest__.html#a46c6f9d85a9286f37692778a3aacd393).[hiStop](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEJointProperties__.html#a3aca5a03f65a3709d121d5e51dde73e8)[[i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392)]);
    01324         for(unsigned int [i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392)=0;[i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392)< req.[ode_joint_config](../../gazebo_msgs/html/structgazebo__msgs_1_1SetJointPropertiesRequest__.html#a46c6f9d85a9286f37692778a3aacd393).[loStop](../../gazebo_msgs/html/structgazebo__msgs_1_1ODEJointProperties__.html#a74f82eb47721f4e8ee30834a7cc72035).size();[i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392)++)


git clone https://github.com/davetcoleman/baxter_common.git -b dual_parallel_grippers


[ _≪_ Previous: Start actor trajectory from plugin
](//gazebo214.rssing.com/chan-57893035/latest.php#c57893035a6944 "Previous
Article")


[ ](//www.rssing.com/index.php)


**[ TheDash ](/TheDash) ** commented  Jan 11, 2021


I tried the previous method [ #93 (comment) ](https://github.com/ros-
simulation/gazebo_ros_pkgs/issues/93#issuecomment-389708864) , but it doesn't
work for gazebo 9 and bullet physics engine. And it works for gazebo9 with ODE
or dart physics engines.


![The Umbrella Academy’s Justin Min shares adorable first selfie with new
boyfriend](//metro.co.uk/wp-content/uploads/2020/03/JUSTIN-MIN-2-0be4.png)


#  Provide feedback


World files are found within the ` /worlds ` directory of your Gazebo resource
path. The location of this path depends on how you installed Gazebo and the
type of system your are on. To find the location of your Gazebo resources, use
the following command:


###  [ Wicked Cool Toys Announces 'The Loud House' Plush Toy Line | NYTF 2018
[Updated]
](////nickalive1.rssing.com/chan-12111484/article19428.html#c12111484a19428i709189718)


**[ josephcoombe ](/josephcoombe) ** commented  Aug 16, 2018


Copy link


Sorry, something went wrong.


[ English  ](javascript:; "English")


Collaborator


[Spawn.cc:289] Spawn plugin is using camera [scene::Camera(65527)] [GUI] [Msg]
Loading plugin [ignition-rendering-ogre2] [GUI] [Dbg] [SelectEntities.cc:451]
SelectEntities plugin is using camera [scene::Camera(65527)] [GUI] [Msg]
Loading plugin [ignition-rendering-ogre2] [GUI] [Dbg] [MarkerManager.cc:173]
Advertise /marker/list service. [GUI] [Dbg] [MarkerManager.cc:183] Advertise
/marker/list. [GUI] [Dbg] [MarkerManager.cc:193] Advertise /marker_array.
[GUI] [Msg] Loading plugin [ignition-rendering-ogre2] [GUI] [Dbg]
[CameraTracking.cc:181] CameraTrackingPrivate plugin is moving camera
[scene::Camera(65527)] [GUI] [Msg] Move to service on [/gui/move_to] [GUI]
[Msg] Follow service on [/gui/follow] [GUI] [Msg] Move to pose service on
[/gui/move_to/pose] [GUI] [Msg] Camera pose topic advertised on
[/gui/camera/pose] [GUI] [Msg] Follow offset service on [/gui/follow/offset]
[GUI] [Msg] Loading plugin [ignition-rendering-ogre2] [GUI] [Dbg]
[InteractiveViewControl.cc:130] InteractiveViewControl plugin is moving camera
[scene::Camera(65527)] [GUI] [Msg] Loading plugin [ignition-rendering-ogre2]
[GUI] [Msg] Loading plugin [ignition-rendering-ogre2] [GUI] [Dbg]
[EntityContextMenuPlugin.cc:79] Entity context menu plugin is using camera
[scene::Camera(65527)] [GUI] [Wrn] [Application.cc:797] [QT]
file::/Gazebo/GazeboDrawer.qml:147:3: QML Dialog: Binding loop detected for
property "implicitHeight" I will also provide an example of what happens when
i remove the reference to the plugin from the world file ign gazebo
custom_plugin.world -v 4 [Msg] Ignition Gazebo GUI v6.11.0 [Dbg] [ign.cc:161]
Subscribing to [/gazebo/starting_world]. [Dbg] [ign.cc:163] Waiting for a
world to be set from the GUI... [Dbg] [Gui.cc:253] Waiting for subscribers to
[/gazebo/starting_world]... [Msg] Received world [custom_plugin.world] from
the GUI. [Dbg] [ign.cc:167] Unsubscribing from [/gazebo/starting_world]. [Msg]
Ignition Gazebo Server v6.11.0 Warning: Ignoring XDG_SESSION_TYPE=wayland on
Gnome. Use QT_QPA_PLATFORM=wayland to run on Wayland anyway. [Msg] Loading SDF
world
file[/home/sperospace/Git/Robotic_Arm/01_Prototypes/03_Gecko/04_simulation/simulation_packages/src/environments/worlds/custom_plugin.world].
[Dbg] [Application.cc:92] Initializing application. [GUI] [Dbg]
[Application.cc:555] Create main window [Msg] Serving entity system service on
[/entity/system/add] [Msg] Loaded level [3] [Msg] No systems loaded from SDF,
loading defaults [Dbg] [ServerConfig.cc:1027] Loaded (3) plugins from file
[/home/sperospace/.ignition/gazebo/6/server.config] [Dbg] [Physics.cc:803]
Loaded [ignition::physics::dartsim::Plugin] from library
[/usr/lib/x86_64-linux-gnu/ign-physics-5/engine-plugins/libignition-physics-
dartsim-plugin.so] [Dbg] [SystemManager.cc:58] Loaded system
[ignition::gazebo::systems::Physics] for entity [1] [Msg] Create service on
[/world/default/create] [Msg] Remove service on [/world/default/remove] [Msg]


###  [ 5 Dromlee Crescent, Beaumont, Dublin 9 - €399,950
](////myhome191.rssing.com/chan-15086300/article8401.html#c15086300a8401i282862088)


The mirror would be


**[ hsu ](/hsu) ** commented  Aug 8, 2014


[ https://bitbucket.org/osrf/gazebo/issue/1138/set-joint-positions-in-
jointcontroller ](https://bitbucket.org/osrf/gazebo/issue/1138/set-joint-
positions-in-jointcontroller)


Already on GitHub? [ Sign in ](/login?return_to=%2Fros-
simulation%2Fgazebo_ros_pkgs%2Fissues%2Fnew%2Fchoose) to your account


#  Saved searches


[ ](javascript:; "Like") 0


[ ](javascript:; "Ouch") 0


Resources


[ ](javascript:; "Share Article") [
](//www.rssing.com/contact.php?r=o6&u=%2F%2Fgazebo214.rssing.com%2Fchan-57893035%2Flatest-
article21-live.php "Article Support")


    00981         res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1GetModelStateResponse__.html#a2ac60b79617ca44e69200efbafe6d3ee) = "GetModelState: got properties";
    00982         return true;
    00983       }
    00984     }
    00985
    [00988](classGazeboROSNode.html#a981d4d5169d7bd4f3198ff1624ac32cb)     bool [getModelProperties](classGazeboROSNode.html#a981d4d5169d7bd4f3198ff1624ac32cb)([gazebo_msgs::GetModelProperties::Request](../../gazebo_msgs/html/structgazebo__msgs_1_1GetModelPropertiesRequest__.html) &req,[gazebo_msgs::GetModelProperties::Response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetModelPropertiesResponse__.html) &res)
    00989     {
    00990       gazebo::Model* model = dynamic_cast<gazebo::Model*>(gazebo::World::Instance()->GetEntityByName(req.[model_name](../../gazebo_msgs/html/structgazebo__msgs_1_1GetModelPropertiesRequest__.html#aec59b6472b1994d20e76b7632e205374)));
    00991       if (!model)
    00992       {
    00993         [ROS_ERROR](../../../api/rosconsole/html/macros__generated_8h.html#a7fb635b03cc608284eadecd2f8becd9a)("GetModelProperties: model [%s] does not exist",req.[model_name](../../gazebo_msgs/html/structgazebo__msgs_1_1GetModelPropertiesRequest__.html#aec59b6472b1994d20e76b7632e205374).c_str());
    00994         res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1GetModelPropertiesResponse__.html#a37b00b8f7dff2d63ad76237f5d8df7eb) = false;
    00995         res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1GetModelPropertiesResponse__.html#a2cf1722eb607280ff503bd5c78d51fd0) = "GetModelProperties: model does not exist";
    00996         return false;
    00997       }
    00998       else
    00999       {
    01000         // get model parent name
    01001         gazebo::Entity* parent_model = model->GetParent();
    01002         if (parent_model) res.[parent_model_name](../../gazebo_msgs/html/structgazebo__msgs_1_1GetModelPropertiesResponse__.html#a9c1ce8aad7e2df1f3416b10284acdf25) = parent_model->GetName();
    01003
    01004         // get list of child bodies, geoms
    01005         res.[body_names](../../gazebo_msgs/html/structgazebo__msgs_1_1GetModelPropertiesResponse__.html#a8029852f19a7eff03e9d2c9ac7539369).clear();
    01006         res.[geom_names](../../gazebo_msgs/html/structgazebo__msgs_1_1GetModelPropertiesResponse__.html#a983a7d3fb49a140e26311711058b9c88).clear();
    01007         const std::vector< gazebo::Entity* > entities = model->GetChildren();
    01008         for (std::vector< gazebo::Entity* >::const_iterator eiter = entities.begin();eiter!=entities.end();eiter++)
    01009         {
    01010           gazebo::Body* body = dynamic_cast<gazebo::Body*>(*eiter);
    01011           if (body)
    01012           {
    01013             res.[body_names](../../gazebo_msgs/html/structgazebo__msgs_1_1GetModelPropertiesResponse__.html#a8029852f19a7eff03e9d2c9ac7539369).push_back(body->GetName());
    01014             // get list of geoms
    01015             for (unsigned int [i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392) = 0; [i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392) < body->GetGeomCount() ; [i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392)++)
    01016               res.[geom_names](../../gazebo_msgs/html/structgazebo__msgs_1_1GetModelPropertiesResponse__.html#a983a7d3fb49a140e26311711058b9c88).push_back(body->GetGeom([i](../../../api/ivcon/html/ivcon_8c.html#acb559820d9ca11295b4500f179ef6392))->GetName());
    01017           }
    01018         }
    01019
    01020         // get list of joints
    01021         res.[joint_names](../../gazebo_msgs/html/structgazebo__msgs_1_1GetModelPropertiesResponse__.html#a4e1a0730644ed5ac3f765b40007ee586).clear();
    01022         unsigned int jc = model->GetJointCount();


[
![@corot](https://avatars.githubusercontent.com/u/322610?s=80&u=2c64beaa2207f040c47377e1b106ac4cd8b487fa&v=4)
](/corot)


[ All ](javascript:void\(0\)) [ Classes ](javascript:void\(0\)) [ Namespaces
](javascript:void\(0\)) [ Files ](javascript:void\(0\)) [ Functions
](javascript:void\(0\)) [ Variables ](javascript:void\(0\)) [ Typedefs
](javascript:void\(0\)) [ Enumerations ](javascript:void\(0\)) [ Enumerator
](javascript:void\(0\)) [ Properties ](javascript:void\(0\)) [ Friends
](javascript:void\(0\))


Collaborator  Author


[ ](//www.rssing.com/index.php?zw=2123 "Home") [ $ ](javascript:; "MoMoney")


testing gazebo 1.9 branch next.

---

All reactions


Sorry, something went wrong.


[ ![@hsu](https://avatars.githubusercontent.com/u/138109?s=80&v=4) ](/hsu)


    * [ 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/)


    00488       std::string set_model_state_service_name("set_model_state");
    00489       [ros::AdvertiseServiceOptions](../../../api/roscpp/html/structros_1_1AdvertiseServiceOptions.html) set_model_state_aso = ros::AdvertiseServiceOptions::create<gazebo_msgs::SetModelState>(
    00490           set_model_state_service_name,boost::bind(&[GazeboROSNode::setModelState](classGazeboROSNode.html#ac4af722aa708173354b6aa935fcf3d00),this,_1,_2),
    00491           ros::VoidPtr(), &this->[gazebo_queue_](classGazeboROSNode.html#aaad18c9d54a8736ea6337821de03889a));
    00492       [set_model_state_service_](classGazeboROSNode.html#acd495ec25d2d35e51c5e308ab278d466) = this->[rosnode_](classGazeboROSNode.html#ae9011736edb2ec542d7176cdddeb546d).[advertiseService](../../../api/roscpp/html/classros_1_1NodeHandle.html#ae659319707eb40e8ef302763f7d632da)(set_model_state_aso);
    00493
    00494       // Advertise more services on the custom queue
    00495       std::string apply_joint_effort_service_name("apply_joint_effort");
    00496       [ros::AdvertiseServiceOptions](../../../api/roscpp/html/structros_1_1AdvertiseServiceOptions.html) apply_joint_effort_aso = ros::AdvertiseServiceOptions::create<gazebo_msgs::ApplyJointEffort>(
    00497           apply_joint_effort_service_name,boost::bind(&[GazeboROSNode::applyJointEffort](classGazeboROSNode.html#af9745546aff989b97db487fd056a6437),this,_1,_2),
    00498           ros::VoidPtr(), &this->[gazebo_queue_](classGazeboROSNode.html#aaad18c9d54a8736ea6337821de03889a));
    00499       [apply_joint_effort_service_](classGazeboROSNode.html#ab51b0de7d13b27dbd1e1f9b473bcd66d) = this->[rosnode_](classGazeboROSNode.html#ae9011736edb2ec542d7176cdddeb546d).[advertiseService](../../../api/roscpp/html/classros_1_1NodeHandle.html#ae659319707eb40e8ef302763f7d632da)(apply_joint_effort_aso);
    00500
    00501       // Advertise more services on the custom queue
    00502       std::string set_joint_properties_service_name("set_joint_properties");
    00503       [ros::AdvertiseServiceOptions](../../../api/roscpp/html/structros_1_1AdvertiseServiceOptions.html) set_joint_properties_aso = ros::AdvertiseServiceOptions::create<gazebo_msgs::SetJointProperties>(
    00504           set_joint_properties_service_name,boost::bind(&[GazeboROSNode::setJointProperties](classGazeboROSNode.html#a95acae858b94081270cfe0bf737ebe3e),this,_1,_2),
    00505           ros::VoidPtr(), &this->[gazebo_queue_](classGazeboROSNode.html#aaad18c9d54a8736ea6337821de03889a));
    00506       [set_joint_properties_service_](classGazeboROSNode.html#a2a2dc8937cd326cc608f25e84cd1ec52) = this->[rosnode_](classGazeboROSNode.html#ae9011736edb2ec542d7176cdddeb546d).[advertiseService](../../../api/roscpp/html/classros_1_1NodeHandle.html#ae659319707eb40e8ef302763f7d632da)(set_joint_properties_aso);
    00507
    00508       // Advertise more services on the custom queue
    00509       std::string set_model_configuration_service_name("set_model_configuration");
    00510       [ros::AdvertiseServiceOptions](../../../api/roscpp/html/structros_1_1AdvertiseServiceOptions.html) set_model_configuration_aso = ros::AdvertiseServiceOptions::create<gazebo_msgs::SetModelConfiguration>(
    00511           set_model_configuration_service_name,boost::bind(&[GazeboROSNode::setModelConfiguration](classGazeboROSNode.html#aeec9ad42d7c0628cc49d6d886b8a377d),this,_1,_2),
    00512           ros::VoidPtr(), &this->[gazebo_queue_](classGazeboROSNode.html#aaad18c9d54a8736ea6337821de03889a));
    00513       [set_model_configuration_service_](classGazeboROSNode.html#a90d90e15fd2318bd6d8f4e735348289d) = this->[rosnode_](classGazeboROSNode.html#ae9011736edb2ec542d7176cdddeb546d).[advertiseService](../../../api/roscpp/html/classros_1_1NodeHandle.html#ae659319707eb40e8ef302763f7d632da)(set_model_configuration_aso);
    00514
    00515       // Advertise more services on the custom queue
    00516       std::string set_link_state_service_name("set_link_state");
    00517       [ros::AdvertiseServiceOptions](../../../api/roscpp/html/structros_1_1AdvertiseServiceOptions.html) set_link_state_aso = ros::AdvertiseServiceOptions::create<gazebo_msgs::SetLinkState>(
    00518           set_link_state_service_name,boost::bind(&[GazeboROSNode::setLinkState](classGazeboROSNode.html#a885a6f43b990036c7625cf50a06113fb),this,_1,_2),
    00519           ros::VoidPtr(), &this->[gazebo_queue_](classGazeboROSNode.html#aaad18c9d54a8736ea6337821de03889a));
    00520       [set_link_state_service_](classGazeboROSNode.html#aaba51f3b2d3046753a2458ec5c85ba41) = this->[rosnode_](classGazeboROSNode.html#ae9011736edb2ec542d7176cdddeb546d).[advertiseService](../../../api/roscpp/html/classros_1_1NodeHandle.html#ae659319707eb40e8ef302763f7d632da)(set_link_state_aso);
    00521
    00522       // Advertise more services on the custom queue
    00523       std::string reset_simulation_service_name("reset_simulation");
    00524       [ros::AdvertiseServiceOptions](../../../api/roscpp/html/structros_1_1AdvertiseServiceOptions.html) reset_simulation_aso = ros::AdvertiseServiceOptions::create<std_srvs::Empty>(
    00525           reset_simulation_service_name,boost::bind(&[GazeboROSNode::resetSimulation](classGazeboROSNode.html#ae6b30b92ee4b069ba4e19a27977d8cb7),this,_1,_2),
    00526           ros::VoidPtr(), &this->[gazebo_queue_](classGazeboROSNode.html#aaad18c9d54a8736ea6337821de03889a));
    00527       [reset_simulation_service_](classGazeboROSNode.html#a231ed04b51db92a2961ef73fb576797c) = this->[rosnode_](classGazeboROSNode.html#ae9011736edb2ec542d7176cdddeb546d).[advertiseService](../../../api/roscpp/html/classros_1_1NodeHandle.html#ae659319707eb40e8ef302763f7d632da)(reset_simulation_aso);


**[ k-okada ](/k-okada) ** commented  Nov 27, 2014


[
![@rcywongaa](https://avatars.githubusercontent.com/u/7285669?s=40&u=f519c42eb9805998e455ed5c15cafce90fb2d638&v=4)
](/rcywongaa) [ rcywongaa ](/rcywongaa) mentioned this issue  Apr 25, 2022


` [ Merge pull request ](/ros-
simulation/gazebo_ros_pkgs/commit/838241a5806120e17d08b2b79d89264c5aa44a0e
"Merge pull request #279 from k-okada/93_hydro


Hello everyone, I am trying to find a working solution to close some joints
sharing the same child link. Particularly, I'm trying to describe in URDF and
SDF an Ackermann suspension:
[C:\fakepath\susp2.png](/upfiles/16907406434182178.png). A robot using this
suspension will be spawned in Gazebo and RViz. All the thick, colored lines
indicate revolution axes, the numbers are placed right near the joints:
[C:\fakepath\susp1_1.png](/upfiles/16907415784669383.png) **Used tools**:
\- Ubuntu 20.04
\- ROS 2 Foxy
\- corresponding Gazebo package
\- RViz
**How this should work**:
1\. Whenever a rocker is rotated around Y-axis (for example, **joint 5**), its
rotation is passed to a lever **fixed** to the rocker
2\. then the lever pushes a turnbuckle which is rotating around Y-axis in the
**joint 4**
3\. which is turn pushes the end of a torsion bar (**joint 2**, Y-axis
Revolute-joint) making the torsion bar to rotate around Z-axis in the **joint
1** (at which the torsion bar is connected to a **body_link**)
4\. this makes the other torsion bar's end in the **joint 3** to push back the
second turnbuckle
5\. the second turnbuckle pushes the its common with the second lever **joint
6**
6\. making the second lever to rotate the (fixed to it!) second rocker. I
indicate that the torsion bar is the link which is never a parent to any of
the other links, but always a child-link. There fore I'm dealing with a
closed-loop kinematics (?). **The question**:
How do I describe this all in URDF and/or SDF?
**What was already tried**: I have already tried the 4-bar linkage tutorial
[here](https://classic.gazebosim.org/tutorials?tut=kinematic_loop&cat=), but
nothing works for me. Best regards


###  [ Duas for Difficulties, Ism Adham-'Allah’s Greatest Name' and Secrets of
Ya Hayyu Ya Qayyum
](////salawats2.rssing.com/chan-11490042/article47.html#c11490042a47i371003744)


    00079 #include "[gazebo_msgs/GetPhysicsProperties.h](../../gazebo_msgs/html/GetPhysicsProperties_8h.html)"
    00080
    00081 #include "[gazebo_msgs/SetJointProperties.h](../../gazebo_msgs/html/SetJointProperties_8h.html)"
    00082
    00083 #include "[gazebo_msgs/GetWorldProperties.h](../../gazebo_msgs/html/GetWorldProperties_8h.html)"
    00084
    00085 #include "[gazebo_msgs/GetModelProperties.h](../../gazebo_msgs/html/GetModelProperties_8h.html)"
    00086 #include "[gazebo_msgs/GetModelState.h](../../gazebo_msgs/html/GetModelState_8h.html)"
    00087 #include "[gazebo_msgs/SetModelState.h](../../gazebo_msgs/html/SetModelState_8h.html)"
    00088
    00089 #include "[gazebo_msgs/GetJointProperties.h](../../gazebo_msgs/html/GetJointProperties_8h.html)"
    00090 #include "[gazebo_msgs/ApplyJointEffort.h](../../gazebo_msgs/html/ApplyJointEffort_8h.html)"
    00091
    00092 #include "[gazebo_msgs/GetLinkProperties.h](../../gazebo_msgs/html/GetLinkProperties_8h.html)"
    00093 #include "[gazebo_msgs/SetLinkProperties.h](../../gazebo_msgs/html/SetLinkProperties_8h.html)"
    00094 #include "[gazebo_msgs/SetLinkState.h](../../gazebo_msgs/html/SetLinkState_8h.html)"
    00095 #include "[gazebo_msgs/GetLinkState.h](../../gazebo_msgs/html/GetLinkState_8h.html)"
    00096
    00097 // Topics
    00098 #include "[gazebo_msgs/ModelState.h](../../gazebo_msgs/html/ModelState_8h.html)"
    00099 #include "[gazebo_msgs/LinkState.h](../../gazebo_msgs/html/LinkState_8h.html)"
    00100 #include "[gazebo_msgs/ModelStates.h](../../gazebo_msgs/html/ModelStates_8h.html)"
    00101 #include "[gazebo_msgs/LinkStates.h](../../gazebo_msgs/html/LinkStates_8h.html)"
    00102
    00103 #include "[geometry_msgs/Vector3.h](../../../api/geometry_msgs/html/Vector3_8h.html)"
    00104 #include "[geometry_msgs/Wrench.h](../../../api/geometry_msgs/html/Wrench_8h.html)"
    00105 #include "[geometry_msgs/Pose.h](../../../api/geometry_msgs/html/Pose_8h.html)"
    00106 #include "[geometry_msgs/Twist.h](../../../api/geometry_msgs/html/Twist_8h.html)"
    00107
    00108 // For physics dynamics reconfigure
    00109 #include <dynamic_reconfigure/server.h>
    00110 #include <gazebo/PhysicsConfig.h>
    00111 #include "[gazebo_msgs/SetPhysicsProperties.h](../../gazebo_msgs/html/SetPhysicsProperties_8h.html)"
    00112 #include "[gazebo_msgs/GetPhysicsProperties.h](../../gazebo_msgs/html/GetPhysicsProperties_8h.html)"
    00113
    00114 // For model pose transform to set custom joint angles
    00115 #include <[ros/ros.h](../../../api/roscpp/html/ros_8h.html)>
    00116 #include <[urdf/model.h](../../../api/urdf/html/model_8h.html)>
    00117 #include "LinearMath/btTransform.h"
    00118 #include "LinearMath/btVector3.h"


I also noticed that while the simple model worked fine, other models may not
work. Maybe a race condition somewhere at start up? Will look into this in
more detail.

---

All reactions


[ ](javascript:; "Ouch") 0


    <launch>
      <!-- We resume the logic in empty_world.launch, changing only the name of the world to be launched -->
      <include file="$(find gazebo_ros)/launch/empty_world.launch">
        <arg name="world_name" value="$(find MYROBOT_gazebo)/worlds/MYROBOT.world"/>
        <!-- more default parameters can be changed here -->
      </include>
    </launch>


[ ](javascript:; "Share Article") [
](//www.rssing.com/contact.php?r=o6&u=%2F%2Fgazebo214.rssing.com%2Fchan-57893035%2Flatest-
article4-live.php "Article Support")


###  [ Calgary Hells Angels implicated in another fraud
](////hullabaloo16.rssing.com/chan-9145637/article818.html#c9145637a818i695428444)


To accomplish this method, you must make a new model database that contains
just your single robot. This isn't the cleanest way to load your URDF into
Gazebo but accomplishes the goal of not having to keep two copies of your
robot URDF on your computer. If the following instructions are confusing,
refer back to the [ Gazebo Model Database
](http://gazebosim.org/user_guide/started__models__database.html)
documentation to understand why these steps are required.


This hierarchy is specially adapted for use as a Gazebo model database by
means of the following folders/files:


    roslaunch gazebo_ros willowgarage_world.launch
    roslaunch gazebo_ros mud_world.launch
    roslaunch gazebo_ros shapes_world.launch
    roslaunch gazebo_ros rubble_world.launch


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


Is there any solution in sight for this? It's still occuring on
Kinetic+gazebo7.


    00691       if (gazebo::World::Instance()->GetEntityByName(model_name))
    00692       {
    00693         [ROS_ERROR](../../../api/rosconsole/html/macros__generated_8h.html#a7fb635b03cc608284eadecd2f8becd9a)("SpawnModel: Failure - model name %s already exist.",model_name.c_str());
    00694         res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelResponse__.html#a5ec6d9587b9a10ddc10ec198d41ccd62) = false;
    00695         res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelResponse__.html#acb4913011a74e88bdac7e11d173d8a7b) = "SpawnModel: Failure - model already exists.";
    00696         return false;
    00697       }
    00698
    00699       // get name space for the corresponding model plugins
    00700       std::string robot_namespace = req.[robot_namespace](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#a3c578c1623a220e86e6ef67489356b12);
    00701
    00702       // get initial pose of model
    00703       gazebo::Vector3 initial_xyz(req.[initial_pose](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#ace209c26c913dacf3112e94d343be2b0).[position](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Pose__.html#a27067d1772d85a856b0e4ed4690a80b4).[x](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Point__.html#acd9420e6916084b2a9c09019bfda1708),req.[initial_pose](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#ace209c26c913dacf3112e94d343be2b0).[position](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Pose__.html#a27067d1772d85a856b0e4ed4690a80b4).[y](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Point__.html#a46a84ff5a3e5817ab5693abda66fccb0),req.[initial_pose](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#ace209c26c913dacf3112e94d343be2b0).[position](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Pose__.html#a27067d1772d85a856b0e4ed4690a80b4).[z](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Point__.html#a061f0093e927a95998f35ceceb5cebda));
    00704       // get initial roll pitch yaw (fixed frame transform)
    00705       gazebo::Quatern initial_q(req.[initial_pose](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#ace209c26c913dacf3112e94d343be2b0).[orientation](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Pose__.html#af8c1d34a44a7628ea9c3e571339f5a28).[w](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Quaternion__.html#a440791d268a65607ecbac21e0ed153cf),req.[initial_pose](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#ace209c26c913dacf3112e94d343be2b0).[orientation](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Pose__.html#af8c1d34a44a7628ea9c3e571339f5a28).[x](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Quaternion__.html#a11f3b4e2df587ce516fd2a8140c1c7c5),req.[initial_pose](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#ace209c26c913dacf3112e94d343be2b0).[orientation](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Pose__.html#af8c1d34a44a7628ea9c3e571339f5a28).[y](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Quaternion__.html#a601c978178311ce3a618afb38c0b6b98),req.[initial_pose](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#ace209c26c913dacf3112e94d343be2b0).[orientation](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Pose__.html#af8c1d34a44a7628ea9c3e571339f5a28).[z](../../../api/geometry_msgs/html/structgeometry__msgs_1_1Quaternion__.html#ae2caceb9fc4b2fd01acd8419aa7ebc2e));
    00706
    00707       // refernce frame for initial pose definition, modify initial pose if defined
    00708       gazebo::Body* frame = dynamic_cast<gazebo::Body*>(gazebo::World::Instance()->GetEntityByName(req.[reference_frame](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#af510727d31cfdbdd303809f180ecf421)));
    00709       if (frame)
    00710       {
    00711         // convert to relative pose
    00712         gazebo::Pose3d frame_pose = frame->GetWorldPose();
    00713         initial_xyz = frame_pose.rot.RotateVector(initial_xyz);
    00714         initial_xyz += frame_pose.pos;
    00715         initial_q = frame_pose.rot*initial_q;
    00716       }
    00717
    00719       else if (req.[reference_frame](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#af510727d31cfdbdd303809f180ecf421) == "" || req.[reference_frame](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#af510727d31cfdbdd303809f180ecf421) == "world" || req.[reference_frame](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#af510727d31cfdbdd303809f180ecf421) == "map" || req.[reference_frame](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#af510727d31cfdbdd303809f180ecf421) == "/map")
    00720       {
    00721           [ROS_DEBUG](../../../api/rosconsole/html/macros__generated_8h.html#a83228c0b42c80605abdd0f42af64b1f7)("SpawnModel: reference_frame is empty/world/map, using inertial frame");
    00722       }
    00723       else
    00724       {
    00725         res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelResponse__.html#a5ec6d9587b9a10ddc10ec198d41ccd62) = false;
    00726         res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelResponse__.html#acb4913011a74e88bdac7e11d173d8a7b) = "SpawnModel: reference reference_frame not found, did you forget to scope the link by model name?";
    00727         return false;
    00728       }
    00729
    00730       // incoming robot model string
    00731       std::string model_xml = req.[model_xml](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#a4ea852fe421bee28bcaa852e69e13004);


On Thu, Aug 7, 2014 at 11:54 PM, Daniel Solomon [ notifications@github.com
](mailto:notifications@github.com)
wrote:


    02160         config.max_contacts                = srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).ode_config.max_contacts;
    02161         [physics_reconfigure_initialized_](classGazeboROSNode.html#a2181c5f39b7ef9e85ef3382e53f66b40) = true;
    02162       }
    02163       else
    02164       {
    02165         bool changed = false;
    02166         [gazebo_msgs::GetPhysicsProperties](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html) srv;
    02167         this->[physics_reconfigure_get_client_](classGazeboROSNode.html#a7dd692c657f72627df72e9b765679a10).[call](../../../api/roscpp/html/classros_1_1ServiceClient.html#ad7f2499f8fcdc6598e284bc6094d2d77)(srv);
    02168
    02169         // check for changes
    02170         if (config.time_step                      != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).time_step)                                 changed = true;
    02171         if (config.max_update_rate                != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).max_update_rate)                           changed = true;
    02172         if (config.gravity_x                      != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).gravity.x)                                 changed = true;
    02173         if (config.gravity_y                      != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).gravity.y)                                 changed = true;
    02174         if (config.gravity_z                      != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).gravity.z)                                 changed = true;
    02175         if (config.auto_disable_bodies            != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).ode_config.auto_disable_bodies)            changed = true;
    02176         if (([uint32_t](../../../api/rxtools/html/namespacerxtools.html#a4df59b602fbf4c488b2e8eebe9a516ec))config.sor_pgs_precon_iters != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).ode_config.sor_pgs_precon_iters)           changed = true;
    02177         if (([uint32_t](../../../api/rxtools/html/namespacerxtools.html#a4df59b602fbf4c488b2e8eebe9a516ec))config.sor_pgs_iters        != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).ode_config.sor_pgs_iters)                  changed = true;
    02178         if (config.sor_pgs_rms_error_tol          != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).ode_config.sor_pgs_rms_error_tol)          changed = true;
    02179         if (config.sor_pgs_w                      != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).ode_config.sor_pgs_w)                      changed = true;
    02180         if (config.contact_surface_layer          != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).ode_config.contact_surface_layer)          changed = true;
    02181         if (config.contact_max_correcting_vel     != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).ode_config.contact_max_correcting_vel)     changed = true;
    02182         if (config.cfm                            != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).ode_config.cfm)                            changed = true;
    02183         if (config.erp                            != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).ode_config.erp)                            changed = true;
    02184         if (([uint32_t](../../../api/rxtools/html/namespacerxtools.html#a4df59b602fbf4c488b2e8eebe9a516ec))config.max_contacts         != srv.[response](../../gazebo_msgs/html/structgazebo__msgs_1_1GetPhysicsProperties.html#aef0d0e922e15a50ec7d09bfb39cf321a).ode_config.max_contacts)                   changed = true;
    02185
    02186         if (changed)
    02187         {
    02188           // pause simulation if requested
    02189           [gazebo_msgs::SetPhysicsProperties](../../gazebo_msgs/html/structgazebo__msgs_1_1SetPhysicsProperties.html) srv;
    02190           srv.[request](../../gazebo_msgs/html/structgazebo__msgs_1_1SetPhysicsProperties.html#a22bea3bf369b87d15113cb3d76cf3ae3).time_step                             = config.time_step                   ;
    02191           srv.[request](../../gazebo_msgs/html/structgazebo__msgs_1_1SetPhysicsProperties.html#a22bea3bf369b87d15113cb3d76cf3ae3).max_update_rate                       = config.max_update_rate             ;
    02192           srv.[request](../../gazebo_msgs/html/structgazebo__msgs_1_1SetPhysicsProperties.html#a22bea3bf369b87d15113cb3d76cf3ae3).gravity.x                             = config.gravity_x                   ;
    02193           srv.[request](../../gazebo_msgs/html/structgazebo__msgs_1_1SetPhysicsProperties.html#a22bea3bf369b87d15113cb3d76cf3ae3).gravity.y                             = config.gravity_y                   ;
    02194           srv.[request](../../gazebo_msgs/html/structgazebo__msgs_1_1SetPhysicsProperties.html#a22bea3bf369b87d15113cb3d76cf3ae3).gravity.z                             = config.gravity_z                   ;
    02195           srv.[request](../../gazebo_msgs/html/structgazebo__msgs_1_1SetPhysicsProperties.html#a22bea3bf369b87d15113cb3d76cf3ae3).ode_config.auto_disable_bodies        = config.auto_disable_bodies         ;
    02196           srv.[request](../../gazebo_msgs/html/structgazebo__msgs_1_1SetPhysicsProperties.html#a22bea3bf369b87d15113cb3d76cf3ae3).ode_config.sor_pgs_precon_iters       = config.sor_pgs_precon_iters        ;
    02197           srv.[request](../../gazebo_msgs/html/structgazebo__msgs_1_1SetPhysicsProperties.html#a22bea3bf369b87d15113cb3d76cf3ae3).ode_config.sor_pgs_iters              = config.sor_pgs_iters               ;
    02198           srv.[request](../../gazebo_msgs/html/structgazebo__msgs_1_1SetPhysicsProperties.html#a22bea3bf369b87d15113cb3d76cf3ae3).ode_config.sor_pgs_rms_error_tol      = config.sor_pgs_rms_error_tol       ;
    02199           srv.[request](../../gazebo_msgs/html/structgazebo__msgs_1_1SetPhysicsProperties.html#a22bea3bf369b87d15113cb3d76cf3ae3).ode_config.sor_pgs_w                  = config.sor_pgs_w                   ;


Copy link


[ ](javascript:; "Share Article") [
](//www.rssing.com/contact.php?r=o6&u=%2F%2Fgazebo214.rssing.com%2Fchan-57893035%2Flatest-
article26-live.php "Article Support")


**[ dpsolomon ](/dpsolomon) ** commented  Aug 8, 2014


    00648       {
    00649         [ROS_ERROR](../../../api/rosconsole/html/macros__generated_8h.html#a7fb635b03cc608284eadecd2f8becd9a)("SpawnModel: Failure - model format is not URDF (nor COLLADA).");
    00650         res.[success](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelResponse__.html#a5ec6d9587b9a10ddc10ec198d41ccd62) = false;
    00651         res.[status_message](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelResponse__.html#acb4913011a74e88bdac7e11d173d8a7b) = "SpawnModel: Failure - model format is not URDF (nor COLLADA).";
    00652         return false;
    00653       }
    00654
    00658       std::string open_bracket("<?");
    00659       std::string close_bracket("?>");
    00660       size_t pos1 = model_xml.find(open_bracket,0);
    00661       size_t pos2 = model_xml.find(close_bracket,0);
    00662       if (pos1 != std::string::npos && pos2 != std::string::npos)
    00663         model_xml.replace(pos1,pos2-pos1+2,std::string(""));
    00664
    00665       [ROS_DEBUG](../../../api/rosconsole/html/macros__generated_8h.html#a83228c0b42c80605abdd0f42af64b1f7)("Model XML\n\n%s\n\n ",model_xml.c_str());
    00666
    00667       [urdf2gazebo::URDF2Gazebo](classurdf2gazebo_1_1URDF2Gazebo.html) u2g;
    00668       TiXmlDocument model_xml_doc;
    00669       model_xml_doc.Parse(model_xml.c_str());
    00670       TiXmlDocument gazebo_model_xml;
    00671       // initial xyz and rpy are empty, will be inserted in spawnGazeboModel
    00672       u2g.convert(model_xml_doc, gazebo_model_xml, enforce_limits, [urdf::Vector3](../../../api/urdf_interface/html/classurdf_1_1Vector3.html)(), [urdf::Vector3](../../../api/urdf_interface/html/classurdf_1_1Vector3.html)(), model_name, robot_namespace);
    00673
    00674       // push to factory iface
    00675       std::ostringstream stream;
    00676       stream << gazebo_model_xml;
    00677       std::string gazebo_model_xml_string = stream.str();
    00678       [ROS_DEBUG](../../../api/rosconsole/html/macros__generated_8h.html#a83228c0b42c80605abdd0f42af64b1f7)("Gazebo Model XML\n\n%s\n\n ",gazebo_model_xml_string.c_str());
    00679       req.[model_xml](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#a4ea852fe421bee28bcaa852e69e13004) = gazebo_model_xml_string;
    00680
    00681       // publish gazebo model on parameter server as [robot_namespace]/gazebo/[model name]/robot_description
    00682       // this->rosnode_.setParam(robot_namespace+std::string("/gazebo/")+model_name+std::string("/robot_description"),gazebo_model_xml_string);
    00683
    00684       return [spawnGazeboModel](classGazeboROSNode.html#a7eb487a51a9a6ecb286f63f537d541f6)(req,res);
    00685     }
    00686
    [00687](classGazeboROSNode.html#a7eb487a51a9a6ecb286f63f537d541f6)     bool [spawnGazeboModel](classGazeboROSNode.html#a7eb487a51a9a6ecb286f63f537d541f6)([gazebo_msgs::SpawnModel::Request](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html) &req,[gazebo_msgs::SpawnModel::Response](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelResponse__.html) &res)
    00688     {
    00689       // check to see if model name already exist as a model
    00690       std::string model_name = req.[model_name](../../gazebo_msgs/html/structgazebo__msgs_1_1SpawnModelRequest__.html#a3f46d36811a6f381a676b7ac60691259);


###  [ 19 Reader-Favourite March Purchases — From Steals To Splurges
](////refinery1042.rssing.com/chan-72297680/article18978.html#c72297680a18978i36572736)