Robotics StackExchange | Archived questions

Franka Emika Panda and Clearpath Ridgeback simulation

I have an integrated Clearpath Ridgeback with Franka Emika Panda. I have updated the URDF and all Gazebo elements accordingly. The URDF seems fine and depicts the original robot and I also verified the gazebo tags for all link and joints in the robot.

My problem is that the simulation does not work when run with one model. But works for each robot i.e. Ridgeback and Panda. The thing is sometimes Gazebo does not launch complaining gzserver died and sometime Gazebo launches but with errors.

Here is the log for the simulation

      roslaunch mbs_rp_gazebo mbs_ridgeback_world.launch 
  ... logging to /home/mbs/.ros/log/5ab89c78-72f9-11ec-94b9-a7c0ea6e7c37/roslaunch-Development-3986.log
  Checking log directory for disk usage. This may take a while.
  Press Ctrl-C to interrupt
  Done checking log file disk usage. Usage is <1GB.

  started roslaunch server http://Development:34975/

  SUMMARY
  ========

  PARAMETERS
  * /ekf_localization/base_link_frame: base_link
  * /ekf_localization/frequency: 50
  * /ekf_localization/imu0: /imu/data
  * /ekf_localization/imu0_config: [False, False, Fa...
  * /ekf_localization/imu0_differential: False
  * /ekf_localization/odom0: /ridgeback_veloci...
  * /ekf_localization/odom0_config: [False, False, Fa...
  * /ekf_localization/odom0_differential: False
  * /ekf_localization/odom_frame: odom
  * /ekf_localization/two_d_mode: True
  * /ekf_localization/world_frame: odom
  * /gazebo/enable_ros_network: True
  * /gazebo_ros_control/pid_gains/front_left_wheel/d: 0
  * /gazebo_ros_control/pid_gains/front_left_wheel/i: 0.1
  * /gazebo_ros_control/pid_gains/front_left_wheel/p: 1
  * /gazebo_ros_control/pid_gains/front_right_wheel/d: 0
  * /gazebo_ros_control/pid_gains/front_right_wheel/i: 0.1
  * /gazebo_ros_control/pid_gains/front_right_wheel/p: 1
  * /gazebo_ros_control/pid_gains/rear_left_wheel/d: 0
  * /gazebo_ros_control/pid_gains/rear_left_wheel/i: 0.1
  * /gazebo_ros_control/pid_gains/rear_left_wheel/p: 1
  * /gazebo_ros_control/pid_gains/rear_right_wheel/d: 0
  * /gazebo_ros_control/pid_gains/rear_right_wheel/i: 0.1
  * /gazebo_ros_control/pid_gains/rear_right_wheel/p: 1
  * /lift_joint_position_controller/gains/d: 0
  * /lift_joint_position_controller/gains/i: 0.1
  * /lift_joint_position_controller/gains/p: 1
  * /lift_joint_position_controller/joint: mbs_lift_joint
  * /lift_joint_position_controller/type: position_controll...
  * /lift_joint_state_controller/publish_rate: 50
  * /lift_joint_state_controller/type: joint_state_contr...
  * /panda/arm_id: panda
  * /panda/cartesian_impedance_example_controller/arm_id: panda
  * /panda/cartesian_impedance_example_controller/joint_names: ['panda_joint1', ...
  * /panda/cartesian_impedance_example_controller/type: franka_example_co...
  * /panda/force_example_controller/arm_id: panda
  * /panda/force_example_controller/joint_names: ['panda_joint1', ...
  * /panda/force_example_controller/type: franka_example_co...
  * /panda/franka_gripper/arm_id: panda
  * /panda/franka_gripper/finger1/gains/d: 20
  * /panda/franka_gripper/finger1/gains/i: 25
  * /panda/franka_gripper/finger1/gains/p: 100
  * /panda/franka_gripper/finger2/gains/d: 20
  * /panda/franka_gripper/finger2/gains/i: 25
  * /panda/franka_gripper/finger2/gains/p: 100
  * /panda/franka_gripper/type: franka_gazebo/Fra...
  * /panda/franka_state_controller/arm_id: panda
  * /panda/franka_state_controller/joint_names: ['panda_joint1', ...
  * /panda/franka_state_controller/publish_rate: 30
  * /panda/franka_state_controller/type: franka_control/Fr...
  * /panda/joint_state_publisher/rate: 30
  * /panda/joint_state_publisher/source_list: ['franka_state_co...
  * /panda/m_ee: 0.76
  * /panda/model_example_controller/arm_id: panda
  * /panda/model_example_controller/type: franka_example_co...
  * /panda/robot_description: <?xml version="1....
  * /ridgeback_joint_publisher/publish_rate: 50
  * /ridgeback_joint_publisher/type: joint_state_contr...
  * /ridgeback_velocity_controller/angular/z/has_acceleration_limits: True
  * /ridgeback_velocity_controller/angular/z/has_velocity_limits: True
  * /ridgeback_velocity_controller/angular/z/max_acceleration: 1.0
  * /ridgeback_velocity_controller/angular/z/max_velocity: 2.0
  * /ridgeback_velocity_controller/back_left_wheel_joint: rear_left_wheel
  * /ridgeback_velocity_controller/back_right_wheel_joint: rear_right_wheel
  * /ridgeback_velocity_controller/cmd_vel_timeout: 0.25
  * /ridgeback_velocity_controller/enable_odom_tf: False
  * /ridgeback_velocity_controller/front_left_wheel_joint: front_left_wheel
  * /ridgeback_velocity_controller/front_right_wheel_joint: front_right_wheel
  * /ridgeback_velocity_controller/linear/x/has_acceleration_limits: True
  * /ridgeback_velocity_controller/linear/x/has_velocity_limits: True
  * /ridgeback_velocity_controller/linear/x/max_acceleration: 2.5
  * /ridgeback_velocity_controller/linear/x/max_velocity: 1.1
  * /ridgeback_velocity_controller/linear/y/has_acceleration_limits: True
  * /ridgeback_velocity_controller/linear/y/has_velocity_limits: True
  * /ridgeback_velocity_controller/linear/y/max_acceleration: 2.5
  * /ridgeback_velocity_controller/linear/y/max_velocity: 1.1
  * /ridgeback_velocity_controller/pose_covariance_diagonal: [0.001, 0.001, 10...
  * /ridgeback_velocity_controller/publish_rate: 50
  * /ridgeback_velocity_controller/twist_covariance_diagonal: [0.001, 0.001, 0....
  * /ridgeback_velocity_controller/type: mecanum_drive_con...
  * /ridgeback_velocity_controller/wheel_radius_multiplier: 1.0
  * /ridgeback_velocity_controller/wheel_separation_multiplier: 1.0
  * /ridgeback_velocity_controller/wheel_separation_x: 0.638
  * /ridgeback_velocity_controller/wheel_separation_y: 0.551
  * /robot_description: <?xml version="1....
  * /rosdistro: noetic
  * /rosversion: 1.15.13
  * /twist_marker_server/linear_scale/x: 1
  * /twist_marker_server/linear_scale/y: 1
  * /twist_marker_server/max_negative_linear_velocity/x: -1
  * /twist_marker_server/max_negative_linear_velocity/y: -1
  * /twist_marker_server/max_positive_linear_velocity/x: 1
  * /twist_marker_server/max_positive_linear_velocity/y: 1
  * /use_sim_time: True

  NODES
    /
      cmd_vel_relay (topic_tools/relay)
      ekf_localization (robot_localization/ekf_localization_node)
      gazebo (gazebo_ros/gzserver)
      gazebo_gui (gazebo_ros/gzclient)
      mbs_rp_controller_spawner (controller_manager/spawner)
      robot_state_publisher (robot_state_publisher/robot_state_publisher)
      twist_marker_server (interactive_marker_twist_server/marker_server)
      urdf_spawner (gazebo_ros/spawn_model)
    /panda/
      joint_state_publisher (joint_state_publisher/joint_state_publisher)
      panda_controller_spawner (controller_manager/spawner)
      robot_state_publisher (robot_state_publisher/robot_state_publisher)

  auto-starting new master
  process[master]: started with pid [4000]
  ROS_MASTER_URI=http://localhost:11311

  setting /run_id to 5ab89c78-72f9-11ec-94b9-a7c0ea6e7c37
  process[rosout-1]: started with pid [4010]
  started core service [/rosout]
  process[robot_state_publisher-2]: started with pid [4017]
  process[gazebo-3]: started with pid [4018]
  process[gazebo_gui-4]: started with pid [4024]
  process[urdf_spawner-5]: started with pid [4032]
  process[ekf_localization-6]: started with pid [4035]
  process[cmd_vel_relay-7]: started with pid [4036]
  process[twist_marker_server-8]: started with pid [4037]
  process[mbs_rp_controller_spawner-9]: started with pid [4047]
  process[panda/panda_controller_spawner-10]: started with pid [4050]
  process[panda/robot_state_publisher-11]: started with pid [4055]
  process[panda/joint_state_publisher-12]: started with pid [4058]
  [INFO] [1641917586.179398, 0.000000]: Controller Spawner: Waiting for service controller_manager/load_controller
  [INFO] [1641917586.249014, 0.000000]: Controller Spawner: Waiting for service controller_manager/load_controller
  [ INFO] [1641917586.813050403]: Finished loading Gazebo ROS API Plugin.
  [ INFO] [1641917586.814544990]: waitForService: Service [/gazebo/set_physics_properties] has not been advertised, waiting...
  [ INFO] [1641917586.974829357]: Finished loading Gazebo ROS API Plugin.
  [ INFO] [1641917586.975940914]: waitForService: Service [/gazebo_gui/set_physics_properties] has not been advertised, waiting...
  [ INFO] [1641917587.396633667]: waitForService: Service [/gazebo/set_physics_properties] is now available.
  [ INFO] [1641917587.441398849]: Physics dynamic reconfigure ready.
  [ WARN] [1641917587.625616173, 2761.811000000]: Failed to meet update rate! Took 2761.8110000000001492
  [ WARN] [1641917587.626916864, 2761.811000000]: Failed to meet update rate! Took 2761.7910000000001673
  Warning [Model.cc:212] Non-unique names detected in XML children of model with name[ridgeback].
  [ INFO] [1641917588.225799798, 2761.919000000]: Laser Plugin: Using the 'robotNamespace' param: '/'
  [ INFO] [1641917588.225939528, 2761.919000000]: Starting Laser Plugin (ns = /)
  [ INFO] [1641917588.227209916, 2761.919000000]: Laser Plugin (ns = /)  <tf_prefix_>, set to ""
  [ INFO] [1641917588.424493712, 2761.919000000]: Laser Plugin: Using the 'robotNamespace' param: '/'
  [ INFO] [1641917588.424536523, 2761.919000000]: Starting Laser Plugin (ns = /)
  [ INFO] [1641917588.425375671, 2761.919000000]: Laser Plugin (ns = /)  <tf_prefix_>, set to ""
  [ INFO] [1641917598.924491524, 2761.919000000]: Ouster laser plugin ready, 64 lasers
  [ INFO] [1641917599.045848651, 2761.919000000]: Loading gazebo_ros_control plugin
  [ INFO] [1641917599.046037920, 2761.919000000]: Starting gazebo_ros_control plugin in namespace: /
  [ INFO] [1641917599.046769332, 2761.919000000]: gazebo_ros_control plugin is waiting for model URDF in parameter [robot_description] on the ROS param server.
  [ERROR] [1641917599.240655775, 2761.919000000]: No p gain specified for pid.  Namespace: /gazebo_ros_control/pid_gains/mbs_lift_joint
  [ERROR] [1641917599.241198161, 2761.919000000]: No p gain specified for pid.  Namespace: /gazebo_ros_control/pid_gains/linear_holder_2_joint
  [ WARN] [1641917599.243173907, 2761.919000000]: Transmission panda_franka_state has more than one joint. Currently the default robot hardware simulation  interface only supports one.
  [ WARN] [1641917599.243211213, 2761.919000000]: Transmission panda_franka_model has more than one joint. Currently the default robot hardware simulation  interface only supports one.
  [ INFO] [1641917599.256684085, 2761.919000000]: Loaded gazebo_ros_control.
  [ INFO] [1641917599.277098771, 2761.919000000]: ForceBasedMove using gains: yaw: 500 x: 10000 y: 10000

  [ INFO] [1641917599.277206495, 2761.919000000]: robotBaseFrame for force based move plugin: base_link

  [ INFO] [1641917599.343752962, 2761.919000000]: GazeboRosJointStatePublisher is going to publish joint: front_rocker
  [ INFO] [1641917599.343813063, 2761.919000000]: Starting GazeboRosJointStatePublisher Plugin (ns = //)!, parent name: ridgeback
  [ INFO] [1641917599.372550069, 2761.919000000]: Loading gazebo_ros_control plugin
  [ INFO] [1641917599.372679623, 2761.919000000]: Starting gazebo_ros_control plugin in namespace: panda
  [ INFO] [1641917599.373086817, 2761.919000000]: gazebo_ros_control plugin is waiting for model URDF in parameter [/panda/robot_description] on the ROS param server.
  [INFO] [1641917599.510437, 2761.919000]: Controller Spawner: Waiting for service controller_manager/switch_controller
  [INFO] [1641917599.513100, 2761.919000]: Controller Spawner: Waiting for service controller_manager/unload_controller
  [INFO] [1641917599.515287, 2761.919000]: Loading controller: ridgeback_joint_publisher
  [ INFO] [1641917599.575630570, 2761.919000000]: Using physics type ode
  [INFO] [1641917599.579029, 2761.919000]: Loading controller: ridgeback_velocity_controller
  [ INFO] [1641917599.580217191, 2761.919000000]: Found transmission interface of joint 'panda_joint1': hardware_interface/EffortJointInterface
  [ INFO] [1641917599.580432074, 2761.919000000]: Found transmission interface of joint 'panda_joint2': hardware_interface/EffortJointInterface
  [ INFO] [1641917599.580473593, 2761.919000000]: Found transmission interface of joint 'panda_joint3': hardware_interface/EffortJointInterface
  [ INFO] [1641917599.580504152, 2761.919000000]: Found transmission interface of joint 'panda_joint4': hardware_interface/EffortJointInterface
  [ INFO] [1641917599.580536783, 2761.919000000]: Found transmission interface of joint 'panda_joint5': hardware_interface/EffortJointInterface
  [ INFO] [1641917599.580568819, 2761.919000000]: Found transmission interface of joint 'panda_joint6': hardware_interface/EffortJointInterface
  [ INFO] [1641917599.580594412, 2761.919000000]: Found transmission interface of joint 'panda_joint7': hardware_interface/EffortJointInterface
  [ INFO] [1641917599.580624839, 2761.919000000]: Found transmission interface 'franka_hw/FrankaStateInterface'
  [ INFO] [1641917599.581470651, 2761.919000000]: Found transmission interface 'franka_hw/FrankaModelInterface'
  [ INFO] [1641917599.582763853, 2761.919000000]: KDL Model initialized for chain from 'panda_link0' -> 'panda_link8'
  [ INFO] [1641917599.601809127, 2761.919000000]: Use the roller's radius rather than the wheel's: 0.
  [ INFO] [1641917599.602565367, 2761.919000000]: No parameter lower_torque_thresholds_nominal found, using default values: 20.000000 20.000000 18.000000 18.000000 16.000000 14.000000 12.000000 
  [ INFO] [1641917599.602617795, 2761.919000000]: Front left wheel joint (wheel0) is : front_left_wheel
  [ INFO] [1641917599.603110469, 2761.919000000]: Back left wheel joint (wheel1) is : rear_left_wheel
  [ INFO] [1641917599.603354095, 2761.919000000]: No parameter upper_torque_thresholds_nominal found, using default values: 20.000000 20.000000 18.000000 18.000000 16.000000 14.000000 12.000000 
  [ INFO] [1641917599.603777180, 2761.919000000]: No parameter lower_torque_thresholds_nominal found, using default values: 20.000000 20.000000 18.000000 18.000000 16.000000 14.000000 12.000000 
  [ INFO] [1641917599.603965872, 2761.919000000]: Back right wheel joint (wheel2) is : rear_right_wheel
  [ INFO] [1641917599.604242778, 2761.919000000]: No parameter upper_torque_thresholds_nominal found, using default values: 20.000000 20.000000 20.000000 25.000000 25.000000 25.000000 
  [ INFO] [1641917599.604772664, 2761.919000000]: Front right wheel joint (wheel3) is : front_right_wheel
  [ INFO] [1641917599.605300472, 2761.919000000]: Controller state will be published at 50Hz.
  [ INFO] [1641917599.606047932, 2761.919000000]: Velocity commands will be considered old if they are older than 0.25s.
  [ INFO] [1641917599.606322496, 2761.919000000]: Base frame_id set to base_link
  [ INFO] [1641917599.606575107, 2761.919000000]: Odom frame_id set to odom
  [ INFO] [1641917599.607290790, 2761.919000000]: Publishing to tf is disabled
  [ INFO] [1641917599.620557734, 2761.919000000]: Loaded gazebo_ros_control.
  [urdf_spawner-5] process has finished cleanly
  log file: /home/mbs/.ros/log/5ab89c78-72f9-11ec-94b9-a7c0ea6e7c37/urdf_spawner-5*.log
  [INFO] [1641917599.739570, 2761.920000]: Controller Spawner: Waiting for service controller_manager/switch_controller
  [INFO] [1641917599.741971, 2761.920000]: Controller Spawner: Waiting for service controller_manager/unload_controller
  [INFO] [1641917599.744425, 2761.920000]: Loading controller: franka_state_controller
  Segmentation fault (core dumped)
  [gazebo-3] process has died [pid 4018, exit code 139, cmd /opt/ros/noetic/lib/gazebo_ros/gzserver -e ode /home/mbs/mbs_dev/mbs_ws/workspaces/mbs_rp_ws/src/third_party/ridgeback/ridgeback_simulator/ridgeback_gazebo/worlds/ridgeback_race.world __name:=gazebo __log:=/home/mbs/.ros/log/5ab89c78-72f9-11ec-94b9-a7c0ea6e7c37/gazebo-3.log].
  log file: /home/mbs/.ros/log/5ab89c78-72f9-11ec-94b9-a7c0ea6e7c37/gazebo-3*.log
  Traceback (most recent call last):
    File "/opt/ros/noetic/lib/python3/dist-packages/rospy/impl/tcpros_base.py", line 569, in connect
  Traceback (most recent call last):
      self.read_header()
    File "/opt/ros/noetic/lib/python3/dist-packages/rospy/impl/tcpros_service.py", line 523, in call
    File "/opt/ros/noetic/lib/python3/dist-packages/rospy/impl/tcpros_base.py", line 664, in read_header
      self._validate_header(read_ros_handshake_header(sock, self.read_buff, self.protocol.buff_size))
    File "/opt/ros/noetic/lib/python3/dist-packages/rosgraph/network.py", line 357, in read_ros_handshake_header
      responses = transport.receive_once()
    File "/opt/ros/noetic/lib/python3/dist-packages/rospy/impl/tcpros_base.py", line 744, in receive_once
      d = sock.recv(buff_size)
  ConnectionResetError: [Errno 104] Connection reset by peer

  During handling of the above exception, another exception occurred:

  Traceback (most recent call last):
    File "/opt/ros/noetic/lib/python3/dist-packages/rospy/impl/tcpros_service.py", line 509, in call
      transport.connect(dest_addr, dest_port, service_uri)
    File "/opt/ros/noetic/lib/python3/dist-packages/rospy/impl/tcpros_base.py", line 596, in connect
      self.stat_bytes += recv_buff(sock, b, p.buff_size)
    File "/opt/ros/noetic/lib/python3/dist-packages/rospy/impl/tcpros_base.py", line 111, in recv_buff
      raise TransportInitError(str(e)) #re-raise i/o error
  rospy.exceptions.TransportInitError: [Errno 104] Connection reset by peer

  During handling of the above exception, another exception occurred:

  Traceback (most recent call last):
    File "/opt/ros/noetic/lib/controller_manager/spawner", line 212, in <module>
      raise TransportTerminated("unable to receive data from sender, check sender's logs for details")
  rospy.exceptions.TransportTerminated: unable to receive data from sender, check sender's logs for details
      if __name__ == '__main__': main()

  During handling of the above exception, another exception occurred:

    File "/opt/ros/noetic/lib/controller_manager/spawner", line 190, in main
  Traceback (most recent call last):
    File "/opt/ros/noetic/lib/controller_manager/spawner", line 212, in <module>
      resp = load_controller(name)
    File "/opt/ros/noetic/lib/python3/dist-packages/rospy/impl/tcpros_service.py", line 442, in __call__
      if __name__ == '__main__': main()
    File "/opt/ros/noetic/lib/controller_manager/spawner", line 190, in main
      return self.call(*args, **kwds)
    File "/opt/ros/noetic/lib/python3/dist-packages/rospy/impl/tcpros_service.py", line 512, in call
      resp = load_controller(name)
      raise ServiceException("unable to connect to service: %s"%e)
    File "/opt/ros/noetic/lib/python3/dist-packages/rospy/impl/tcpros_service.py", line 442, in __call__
  rospy.service.ServiceException: unable to connect to service: [Errno 104] Connection reset by peer
      return self.call(*args, **kwds)
    File "/opt/ros/noetic/lib/python3/dist-packages/rospy/impl/tcpros_service.py", line 533, in call
      raise ServiceException("transport error completing service call: %s"%(str(e)))
  rospy.service.ServiceException: transport error completing service call: unable to receive data from sender, check sender's logs for details
  [INFO] [1641917600.155999, 2761.920000]: Shutting down spawner. Stopping and unloading controllers...
  [INFO] [1641917600.156343, 2761.919000]: Shutting down spawner. Stopping and unloading controllers...
  [INFO] [1641917600.157786, 2761.920000]: Stopping all controllers...
  [INFO] [1641917600.158162, 2761.919000]: Stopping all controllers...
  [WARN] [1641917600.162182, 2761.920000]: Controller Spawner error while taking down controllers: unable to connect to service: [Errno 111] Connection refused
  [WARN] [1641917600.163676, 2761.919000]: Controller Spawner error while taking down controllers: unable to connect to service: [Errno 111] Connection refused
  [mbs_rp_controller_spawner-9] process has died [pid 4047, exit code 1, cmd /opt/ros/noetic/lib/controller_manager/spawner ridgeback_joint_publisher ridgeback_velocity_controller lift_joint_state_controller lift_joint_position_controller __name:=mbs_rp_controller_spawner __log:=/home/mbs/.ros/log/5ab89c78-72f9-11ec-94b9-a7c0ea6e7c37/mbs_rp_controller_spawner-9.log].
  log file: /home/mbs/.ros/log/5ab89c78-72f9-11ec-94b9-a7c0ea6e7c37/mbs_rp_controller_spawner-9*.log
  [panda/panda_controller_spawner-10] process has died [pid 4050, exit code 1, cmd /opt/ros/noetic/lib/controller_manager/spawner franka_state_controller __name:=panda_controller_spawner __log:=/home/mbs/.ros/log/5ab89c78-72f9-11ec-94b9-a7c0ea6e7c37/panda-panda_controller_spawner-10.log].
  log file: /home/mbs/.ros/log/5ab89c78-72f9-11ec-94b9-a7c0ea6e7c37/panda-panda_controller_spawner-10*.log

I am using franka_ros, and ridgeback_simulator package. I found a similar problem here but it has no details or any successful leads here. Any leads on the issue will highly be appreciated.

Asked by Tahir M. on 2022-01-11 11:24:56 UTC

Comments

I am working on simmilar task but with dingo robot and panda and I had the same error with Segmentation fault (core dumped). The cause in my case was not properly providing

No p gain specified for pid.  Namespace: /gazebo_ros_control/pid_gains/mbs_lift_joint

In my launch file to start simulation and spawn model, I am loading parameters

  <rosparam file="$(find franka_gazebo)/config/franka_hw_sim.yaml" subst_value="true" />
  <rosparam file="$(find franka_gazebo)/config/sim_controllers.yaml" subst_value="true" />
  <rosparam command="load" file="$(find dingo_gazebo)/config/gains_omni.yaml"/>

and first two are overwriting the namespace used by the third one, so it cannot be found. I changed the gains_omni.yaml to match the namespace and when found, the error was gone for me. But I am still working on launching both robots in simulation.

Asked by Marabir on 2022-12-13 18:19:05 UTC

Answers