
Hello Ros Community,
Description: I am currently in the process of developing a six-axis manipulator in ROS 2, utilizing MoveIt 2 for motion planning and Gazebo for simulation. Regrettably, I am facing a perplexing issue where the manipulator demonstrates peculiar behavior and instability, particularly when I employ position control as the command interface in Gazebo. To provide further clarity, I have included relevant visuals,launch files and urdf that can be accessed HERE.
I am using ROS2 Humble
To provide more context and aid in troubleshooting, here are the details related to the problem:
I am using the following launch file to start the Gazebo simulation and relevant ROS nodes:
ros2 launch hexa_bot_description gazebo.launch.py use_sim_time:=true
When executing the gazebo.launch.py launch file, the following log messages are displayed:
[INFO] [launch]: All log files can be found below /home/roskuttan/.ros/log/2023-05-31-08-57-10-218724-SILENT-KILLERED-1779 [INFO] [launch]: Default logging verbosity is set to INFO [INFO] [robot_state_publisher-1]: process started with pid [1780] [INFO] [joint_state_publisher-2]: process started with pid [1782] [INFO] [gzserver-3]: process started with pid [1784] [INFO] [gzclient-4]: process started with pid [1786] [INFO] [spawn_entity-5]: process started with pid [1788] [robot_state_publisher-1] [WARN] [1685503631.131584399] [kdl_parser]: The root link base_link has an inertia specified in the URDF, but KDL does not support a root link with an inertia. As a workaround, you can add an extra dummy link to your URDF. [robot_state_publisher-1] [INFO] [1685503631.131687999] [robot_state_publisher]: got segment JAW1_1 [robot_state_publisher-1] [INFO] [1685503631.131721599] [robot_state_publisher]: got segment JAW2_1 [robot_state_publisher-1] [INFO] [1685503631.131729199] [robot_state_publisher]: got segment JAW3_1 [robot_state_publisher-1] [INFO] [1685503631.131734199] [robot_state_publisher]: got segment JAW6_1 [robot_state_publisher-1] [INFO] [1685503631.131738899] [robot_state_publisher]: got segment Jaw4_1 [robot_state_publisher-1] [INFO] [1685503631.131743399] [robot_state_publisher]: got segment Jaw5_1 [robot_state_publisher-1] [INFO] [1685503631.131748099] [robot_state_publisher]: got segment NEMA_3_1 [robot_state_publisher-1] [INFO] [1685503631.131752799] [robot_state_publisher]: got segment NEMA_4_1 [robot_state_publisher-1] [INFO] [1685503631.131757499] [robot_state_publisher]: got segment NEMA_5_1 [robot_state_publisher-1] [INFO] [1685503631.131761999] [robot_state_publisher]: got segment Nema_1_1 [robot_state_publisher-1] [INFO] [1685503631.131766599] [robot_state_publisher]: got segment Nema_2_1 [robot_state_publisher-1] [INFO] [1685503631.131771199] [robot_state_publisher]: got segment Nema_6_1 [robot_state_publisher-1] [INFO] [1685503631.131775699] [robot_state_publisher]: got segment base_link [joint_state_publisher-2] [INFO] [1685503631.388555295] [joint_state_publisher]: Waiting for robot_description to be published on the robot_description topic... [spawn_entity-5] [INFO] [1685503631.573401292] [spawn_entity]: Spawn Entity started [spawn_entity-5] [INFO] [1685503631.573742092] [spawn_entity]: Loading entity published on topic robot_description [spawn_entity-5] /opt/ros/humble/local/lib/python3.10/dist-packages/rclpy/qos.py:307: UserWarning: DurabilityPolicy.RMW_QOS_POLICY_DURABILITY_TRANSIENT_LOCAL is deprecated. Use DurabilityPolicy.TRANSIENT_LOCAL instead. [spawn_entity-5] warnings.warn( [spawn_entity-5] [INFO] [1685503631.575072992] [spawn_entity]: Waiting for entity xml on robot_description [spawn_entity-5] [INFO] [1685503631.577393492] [spawn_entity]: Waiting for service /spawn_entity, timeout = 30 [spawn_entity-5] [INFO] [1685503631.577719191] [spawn_entity]: Waiting for service /spawn_entity [spawn_entity-5] [INFO] [1685503633.833226053] [spawn_entity]: Calling service /spawn_entity [spawn_entity-5] [INFO] [1685503634.191623847] [spawn_entity]: Spawn status: SpawnEntity: Successfully spawned entity [hexa_bot] [gzserver-3] [INFO] [1685503634.323934645] [gazebo_ros2_control]: Loading gazebo_ros2_control plugin [gzserver-3] [INFO] [1685503634.327896245] [gazebo_ros2_control]: Starting gazebo_ros2_control plugin in namespace: / [gzserver-3] [INFO] [1685503634.328103945] [gazebo_ros2_control]: Starting gazebo_ros2_control plugin in ros 2 node: gazebo_ros2_control [gzserver-3] [INFO] [1685503634.328150045] [gazebo_ros2_control]: Loading parameter files /home/roskuttan/hexa_bot_ws/install/hexa_bot_description/share/hexa_bot_description/config/hexa_bot.yaml [gzserver-3] [INFO] [1685503634.331047945] [gazebo_ros2_control]: connected to service!! robot_state_publisher [gzserver-3] [INFO] [1685503634.331636045] [gazebo_ros2_control]: Recieved urdf from param server, parsing... [gzserver-3] [INFO] [1685503634.339149145] [gazebo_ros2_control]: Loading joint: joint_1 [gzserver-3] [INFO] [1685503634.339277145] [gazebo_ros2_control]: State: [gzserver-3] [INFO] [1685503634.339294445] [gazebo_ros2_control]: position [gzserver-3] [INFO] [1685503634.339308445] [gazebo_ros2_control]: found initial value: 0.000000 [gzserver-3] [INFO] [1685503634.339355745] [gazebo_ros2_control]: velocity [gzserver-3] [INFO] [1685503634.339370145] [gazebo_ros2_control]: Command: [gzserver-3] [INFO] [1685503634.339380745] [gazebo_ros2_control]: position [gzserver-3] [INFO] [1685503634.339434745] [gazebo_ros2_control]: Loading joint: joint_2 [gzserver-3] [INFO] [1685503634.339447245] [gazebo_ros2_control]: State: [gzserver-3] [INFO] [1685503634.339457845] [gazebo_ros2_control]: position [gzserver-3] [INFO] [1685503634.339467945] [gazebo_ros2_control]: found initial value: 0.000000 [gzserver-3] [INFO] [1685503634.339480145] [gazebo_ros2_control]: velocity [gzserver-3] [INFO] [1685503634.339490045] [gazebo_ros2_control]: Command: [gzserver-3] [INFO] [1685503634.339500045] [gazebo_ros2_control]: position [gzserver-3] [INFO] [1685503634.339518345] [gazebo_ros2_control]: Loading joint: joint_3 [gzserver-3] [INFO] [1685503634.339529145] [gazebo_ros2_control]: State: [gzserver-3] [INFO] [1685503634.339539545] [gazebo_ros2_control]: position [gzserver-3] [INFO] [1685503634.339549045] [gazebo_ros2_control]: found initial value: 0.000000 [gzserver-3] [INFO] [1685503634.339560345] [gazebo_ros2_control]: velocity [gzserver-3] [INFO] [1685503634.339570345] [gazebo_ros2_control]: Command: [gzserver-3] [INFO] [1685503634.339580945] [gazebo_ros2_control]: position [gzserver-3] [INFO] [1685503634.339596745] [gazebo_ros2_control]: Loading joint: joint_4 [gzserver-3] [INFO] [1685503634.339607345] [gazebo_ros2_control]: State: [gzserver-3] [INFO] [1685503634.339617045] [gazebo_ros2_control]: position [gzserver-3] [INFO] [1685503634.339625945] [gazebo_ros2_control]: found initial value: 0.000000 [gzserver-3] [INFO] [1685503634.339637045] [gazebo_ros2_control]: velocity [gzserver-3] [INFO] [1685503634.339646245] [gazebo_ros2_control]: Command: [gzserver-3] [INFO] [1685503634.339656045] [gazebo_ros2_control]: position [gzserver-3] [INFO] [1685503634.339673545] [gazebo_ros2_control]: Loading joint: joint_5 [gzserver-3] [INFO] [1685503634.339681245] [gazebo_ros2_control]: State: [gzserver-3] [INFO] [1685503634.339687245] [gazebo_ros2_control]: position [gzserver-3] [INFO] [1685503634.339693645] [gazebo_ros2_control]: found initial value: 0.000000 [gzserver-3] [INFO] [1685503634.339701245] [gazebo_ros2_control]: velocity [gzserver-3] [INFO] [1685503634.339707145] [gazebo_ros2_control]: Command: [gzserver-3] [INFO] [1685503634.339713145] [gazebo_ros2_control]: position [gzserver-3] [INFO] [1685503634.339722645] [gazebo_ros2_control]: Loading joint: joint_6 [gzserver-3] [INFO] [1685503634.339729245] [gazebo_ros2_control]: State: [gzserver-3] [INFO] [1685503634.339735045] [gazebo_ros2_control]: position [gzserver-3] [INFO] [1685503634.339740545] [gazebo_ros2_control]: found initial value: 0.000000 [gzserver-3] [INFO] [1685503634.339747545] [gazebo_ros2_control]: velocity [gzserver-3] [INFO] [1685503634.339753445] [gazebo_ros2_control]: Command: [gzserver-3] [INFO] [1685503634.339759445] [gazebo_ros2_control]: position [gzserver-3] [INFO] [1685503634.339879245] [resource_manager]: Initialize hardware 'GazeboSystem' [gzserver-3] [INFO] [1685503634.340063045] [resource_manager]: Successful initialization of hardware 'GazeboSystem' [gzserver-3] [INFO] [1685503634.340181345] [resource_manager]: 'configure' hardware 'GazeboSystem' [gzserver-3] [INFO] [1685503634.340187145] [resource_manager]: Successful 'configure' of hardware 'GazeboSystem' [gzserver-3] [INFO] [1685503634.340192045] [resource_manager]: 'activate' hardware 'GazeboSystem' [gzserver-3] [INFO] [1685503634.340195145] [resource_manager]: Successful 'activate' of hardware 'GazeboSystem' [gzserver-3] [INFO] [1685503634.340283245] [gazebo_ros2_control]: Loading controller_manager [gzserver-3] [INFO] [1685503634.357185244] [gazebo_ros2_control]: Loaded gazebo_ros2_control. [INFO] [spawn_entity-5]: process has finished cleanly [pid 1788] [INFO] [ros2-6]: process started with pid [1934] [INFO] [ros2-7]: process started with pid [1936] [gzserver-3] [INFO] [1685503635.299160028] [controller_manager]: Loading controller 'joint_state_broadcaster' [gzserver-3] [INFO] [1685503635.312398828] [controller_manager]: Setting use_sim_time=True for joint_state_broadcaster to match controller manager (see ros2_control#325 for details) [gzserver-3] [INFO] [1685503635.315865028] [controller_manager]: Configuring controller 'joint_state_broadcaster' [gzserver-3] [INFO] [1685503635.316443328] [joint_state_broadcaster]: 'joints' or 'interfaces' parameter is empty. All available state interfaces will be published [gzserver-3] [INFO] [1685503639.271185105] [controller_manager]: Loading controller 'arm_controller' [ros2-7] Sucessfully loaded controller joint_state_broadcaster into state active [gzserver-3] [INFO] [1685503639.293424404] [controller_manager]: Setting use_sim_time=True for arm_controller to match controller manager (see ros2_control#325 for details) [gzserver-3] [INFO] [1685503639.296883904] [controller_manager]: Configuring controller 'arm_controller' [gzserver-3] [INFO] [1685503639.297277404] [arm_controller]: No specific joint names are used for command interfaces. Using 'joints' parameter. [gzserver-3] [INFO] [1685503639.297381904] [arm_controller]: Command interfaces are [position] and state interfaces are [position velocity]. [gzserver-3] [INFO] [1685503639.297455104] [arm_controller]: Using 'splines' interpolation method. [gzserver-3] [INFO] [1685503639.299070304] [arm_controller]: Controller state will be published at 50.00 Hz. [gzserver-3] [INFO] [1685503639.300950304] [arm_controller]: Action status changes will be monitored at 20.00 Hz. [ros2-6] Sucessfully loaded controller arm_controller into state active [INFO] [ros2-7]: process has finished cleanly [pid 1936] [INFO] [ros2-6]: process has finished cleanly [pid 1934] [INFO] [gzclient-4]: process has finished cleanly [pid 1786]
Originally posted by Roskuttan on ROS Answers with karma: 53 on 2023-05-31
Post score: 2
Original comments
Comment by Gio on 2023-05-31:
I'm also having such issues in my project someone help me with a solution it's so urgent I'm at the deadline of my project