Giter VIP home page Giter VIP logo

Comments (5)

sea-bass avatar sea-bass commented on August 15, 2024

Seems the controller is not activated.

[both_arm_controller]: Can't accept new action goals. Controller is not running.

from moveit2_tutorials.

zhangbo9426426 avatar zhangbo9426426 commented on August 15, 2024

Thank you for the tip. I browsed the ros2_controllers.yaml file and it seems to be working fine.The following is the contents of the file:

controller_manager:
ros__parameters:
update_rate: 100

left_arm_controller:
  type: joint_trajectory_controller/JointTrajectoryController


right_arm_controller:
  type: joint_trajectory_controller/JointTrajectoryController


both_arm_controller:
  type: joint_trajectory_controller/JointTrajectoryController


joint_state_broadcaster:
  type: joint_state_broadcaster/JointStateBroadcaster

left_arm_controller:

ros__parameters:
joints:
- robot_joint1_l
- robot_joint2_l
- robot_joint3_l
- robot_joint4_l
- robot_joint5_l
- robot_joint6_l
command_interfaces:
- position
state_interfaces:
- position
- velocity
right_arm_controller:
ros__parameters:
joints:
- robot_joint1_r
- robot_joint2_r
- robot_joint4_r
- robot_joint5_r
- robot_joint6_r
- robot_joint7_r
command_interfaces:
- position
state_interfaces:
- position
- velocity
both_arm_controller:
ros__parameters:
joints:
- robot_joint1_l
- robot_joint2_l
- robot_joint3_l
- robot_joint4_l
- robot_joint5_l
- robot_joint6_l
- robot_joint1_r
- robot_joint2_r
- robot_joint4_r
- robot_joint5_r
- robot_joint6_r
- robot_joint7_r
command_interfaces:
- position
state_interfaces:
- position
- velocity

In addition, when demo.launch is just started, I check the terminal output information about both_arm_controllers as follows:

[spawner-7] [INFO] [1708439166.190132793] [spawner_both_arm_controller]: Loaded both_arm_controller
[ros2_control_node-4] [INFO] [1708439166.191525742] [controller_manager]: Configuring controller 'both_arm_controller'
[ros2_control_node-4] [INFO] [1708439166.191724376] [both_arm_controller]: No specific joint names are used for command interfaces. Using 'joints' parameter.
[ros2_control_node-4] [INFO] [1708439166.191740117] [both_arm_controller]: Command interfaces are [position] and state interfaces are [position velocity].
[ros2_control_node-4] [INFO] [1708439166.191786248] [both_arm_controller]: Using 'splines' interpolation method.
[ros2_control_node-4] [INFO] [1708439166.192174940] [both_arm_controller]: Controller state will be published at 50.00 Hz.
[ros2_control_node-4] [INFO] [1708439166.192842625] [both_arm_controller]: Action status changes will be monitored at 20.00 Hz.
[ros2_control_node-4] [ERROR] [1708439166.208465603] [controller_manager]: Resource conflict for controller 'both_arm_controller'. Command interface 'robot_joint1_l/position' is already claimed.
[spawner-7] [INFO] [1708439166.219404553] [spawner_both_arm_controller]: Configured and activated both_arm_controller

Therer is a error:[controller_manager]: Resource conflict for controller 'both_arm_controller'. Command interface 'robot_joint1_l/position' is already claimed.
I wonder if this error is to blame.

from moveit2_tutorials.

zhangbo9426426 avatar zhangbo9426426 commented on August 15, 2024

It seems that the problem is indeed resource conflict. After I delete the two separate planning groups left_arm and right_arm and keep only the planning group both_arm, I can successfully plan and execute the dual-robot at the same time.

However, when I have three planning groups in ROS1, left_arm, right_arm and both_arm, this problem does not occur. I can plan and execute for single robot or dual-robot.

Is there a solution to this resource conflict problem in moveit2?

from moveit2_tutorials.

sea-bass avatar sea-bass commented on August 15, 2024

Right! Because both_arm_controller claims the same hardware interfaces as the other ones, they can't both be activated at the same time. So you'll need to call into the ros2_control API to activate/deactivate the right controllers.

If you were running your robot from MoveIt2 code (and not RViz), there are ways around it where MoveIt will take care of this for you, like explicitly specifying the controller names you want in your planning request.

Move Group Interface: moveit/moveit2#2257

MoveItCpp: moveit/moveit2#1838

from moveit2_tutorials.

zhangbo9426426 avatar zhangbo9426426 commented on August 15, 2024

Thank you for your answer, I will go to learn about these methods.

from moveit2_tutorials.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.