gazebo ros Segmentation error with publishing arrays

asked 2017-07-14 09:03:14 -0500

Bukmop gravatar image

updated 2017-07-19 03:11:09 -0500

Hello my name is Bukmop and this is my first post here.

I am trying to work with a robot in gazebo and ROS and changing a existing gazebo_ros plugin (gazebo_ros_diff_drive). Now I am facing some problems which don`t really understand.

Preamble:

I am using the code frame from moorerobots and the gazebo_ros plugins (links bellow). My actual code is in GitHub for everyone to access. Furthermore I made a video of the problem I want to solve.

mybot frame: http://moorerobots.com/blog/post/1

original gazebo_ros packages: https://github.com/ros-simulation/gaz...

The GitHub code: https://github.com/Bukmop123/mybot/tr...

Youtube video: https://youtu.be/3iKQuljNhA8

Ubuntu 16.04

gazebo version 7.8.1

ros kinetic

Goal of this work

Basically I have a robot with two Joints and I want set force on these joints and read the actual force and velocity on these Joints. The raw coding is done and it seems to work the way I want it to.

Problem description

When I am starting the code there is different behavior of the launch process as you can see in the video. Here are the relevant parts:

  1. 0.20 min : ok
  2. 0.56 min : Aborted
  3. 1.14 min : Segmentation
  4. 2.03 min : ok
  5. 2.19 min : Segmentation
  6. 2.49 min : ok
  7. 3.08 min : Segmentation
  8. 3.08 min : Segmentation
  9. 3.24 min : Segmentation
  10. 4.01 min : Segmentation and no Gui
  11. 4.18 min : Segmentation
  12. 4.39 min : ok
  13. 5.08 min : Segmentation
  14. 5.25 min : ok
  15. 6.02 min : ok
  16. 6.34 min : ok
  17. 6.55 min : Segmentation
  18. 7.07 min : Aborted
  19. 7.28 min : ok

error notes

17. 6.55 min : Segmentation:

Segmentation fault (core dumped)
[gazebo-2] process has died [pid 26423, exit code 139, cmd /opt/ros/kinetic/lib/gazebo_ros/gzserver -e ode /home/robot/mybot_ws/src/mybot_gazebo/worlds/mybot.world __name:=gazebo __log:=/home/robot/.ros/log/3c2d321c-6888-11e7-9455-c038966d7861/gazebo-2.log].
log file: /home/robot/.ros/log/3c2d321c-6888-11e7-9455-c038966d7861/gazebo-2*.log

18. 7.07 min : Aborted:

Aborted (core dumped)
[gazebo-2] process has died [pid 26910, exit code 134, cmd /opt/ros/kinetic/lib/gazebo_ros/gzserver -e ode /home/robot/mybot_ws/src/mybot_gazebo/worlds/mybot.world __name:=gazebo __log:=/home/robot/.ros/log/46fbdc8e-6888-11e7-9455-c038966d7861/gazebo-2.log].
log file: /home/robot/.ros/log/46fbdc8e-6888-11e7-9455-c038966d7861/gazebo-2*.log
[gazebo_gui-3] process has died [pid 26921, exit code 255, cmd /opt/ros/kinetic/lib/gazebo_ros/gzclient __name:=gazebo_gui __log:=/home/robot/.ros/log/46fbdc8e-6888-11e7-9455-c038966d7861/gazebo_gui-3.log].
log file: /home/robot/.ros/log/46fbdc8e-6888-11e7-9455-c038966d7861/gazebo_gui-3*.log

Observations

The Segmentation errors seems to be less when I use the modified differential_drive_controller but they still appear (2 of 10 maybe ). There seems to be no errors when I use the original differential_drive_controller so the mistake should be somewhere in the code.

Note: You can switch the controller of the joints in mybot.xacro line 9 to 10.

mybot/mybot_ws/src/mybot_description/urdf/mybot.xacro

<xacro:include filename="$(find mybot_description)/urdf/ros_joint_interface_mybot.gazebo" />
<!--xacro:include filename="$(find mybot_description)/urdf/ros_diff_drive_mybot.gazebo" /-->
<!--xacro ...
(more)
edit retag flag offensive close merge delete