Skip to content

Use new ros2_control interfaces #283

Closed

Description

@ShotaAk

Description

The colcon build command of MoveIt 2 Source Build - Linux fails with log message hardware_interface/joint_command_handle.hpp: No such file or directory.

In file included from /home/shotaak/moveit_ws/src/fake_joint/fake_joint_driver/src/fake_joint_driver_node.cpp:10:
/home/shotaak/moveit_ws/src/fake_joint/fake_joint_driver/include/fake_joint_driver/fake_joint_driver.h:12:10: fatal error: hardware_interface/joint_command_handle.hpp: No such file or directory
   12 | #include <hardware_interface/joint_command_handle.hpp>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.

Your environment

  • ROS Distro: Foxy
  • OS Version: Ubuntu 20.04
  • Source build
  • If source, which branch? ddf585c

Steps to reproduce

Reproduce procedure is same as the MoveIt 2 Source Build guide.

Expected behaviour

The build command results success.

Actual behaviour

The build has failed.

In file included from /home/shotaak/moveit_ws/src/fake_joint/fake_joint_driver/src/fake_joint_driver_node.cpp:10:
/home/shotaak/moveit_ws/src/fake_joint/fake_joint_driver/include/fake_joint_driver/fake_joint_driver.h:12:10: fatal error: hardware_interface/joint_command_handle.hpp: No such file or directory
   12 | #include <hardware_interface/joint_command_handle.hpp>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.

Additional context

The file joint_command_handle.hpp has removed by ros-controls/ros2_control#134.

This causes above fake_joint_driver's build error.

Activity

  1. added
    bug
    on Sep 17, 2020
  2. yongxf commented on Sep 17, 2020

    @yongxf

    I went through the same issue. joint_command_handle.hpp cannot be found in moveit2.

  3. henningkayser commented on Sep 17, 2020

    @henningkayser
    Member

    @ShotaAk Thanks for reporting, we've already realized that ros2_control had some breaking changes lately. Until then, it probably makes most sense to fix the commit hash in the repos file and bump the version from time to time until there is a stable API. Were you able to run the demo successfully with an older version?

  4. ShotaAk commented on Sep 17, 2020

    @ShotaAk
    ContributorAuthor

    Yes. I had checkout ros2_control to 2c3aad1cb8ad4d23925bceeb5c26e22d6cf859ef and ros2_controllers to d52902538a970e792ecc604416e22ef90a57f29e, then the demo successfully worked.

  5. destogl commented on Sep 20, 2020

    @destogl
    Contributor

    @henningkayser @ShotaAk we are braking a lot currently in ros2_control in a month or so we should fix new interfaces. If you could use the versions from the comment it would be great :)

  6. henningkayser commented on Sep 21, 2020

    @henningkayser
    Member

    I've created #284 for freezing the ros2_control commits in the workspace. @ShotaAk could you rename this issue to something like "Use new ros2_control interfaces" so that we can continue tracking it in here?

  7. ShotaAk commented on Sep 21, 2020

    @ShotaAk
    ContributorAuthor

    @henningkayser Sure. 👍

  8. changed the title [-]Source build fails[/-] [+]Use new ros2_control interfaces[/+] on Sep 21, 2020
  9. self-assigned this
    on Sep 22, 2020
  10. ShotaAk commented on Sep 25, 2020

    @ShotaAk
    ContributorAuthor

    @henningkayser @JafarAbdi I have replaced old joint handles of fake_joint_driver to new joint handles to solve this issue.
    (See ShotaAk/fake_joint@e888e49)

    May I create a pull request to JafarAbdi/fake_joint?

    (Or should we wait and see the ros2_control proggress?)

  11. henningkayser commented on Sep 25, 2020

    @henningkayser
    Member

    @ShotaAk That's great, thanks! In general, I think it's preferable to stay up to date, but I'd like to first make sure that the API is somewhat stable. The PR would still be very helpful, even if we don't merge it right away.

  12. ShotaAk commented on Sep 25, 2020

    @ShotaAk
    ContributorAuthor

    I'd like to first make sure that the API is somewhat stable

    I understand. Anyway, I will create a PR.

  13. bmagyar commented on Sep 26, 2020

    @bmagyar
    Member

    Hey guys, the current version is functional to a limited extent but the upcoming changes may break API/ABI multiple times, hence the recommendation to stick to a fixed version for the time being. I'll make sure to update you when we reach a stable version.

  14. ShotaAk commented on Sep 27, 2020

    @ShotaAk
    ContributorAuthor

    @bmagyar Thanks. It looks like there will be more updates than just joint handle.

    (I should calm down and see the progress.)

  15. destogl commented on Dec 12, 2020

    @destogl
    Contributor

    Hey people,

    we have now fixed the API for Foxy and you can start to handle this. If you need any help just ping me or @bmagyar

  16. ShotaAk commented on Dec 17, 2020

    @ShotaAk
    ContributorAuthor

    @destogl Thank you for your information.

    I'm trying to use new ros2_control API in our robot (CRANE+V2, https://github.com/rt-net/crane_plus ).
    Is there any migration guide for new API?
    (It seem the joint_command_handle, joint_state_handle and robot_hardware in hardware_interface are deleted.)

  17. destogl commented on Jan 5, 2021

    @destogl
    Contributor

    @ShotaAk I just wrote short documentation in ros-controls/roadmap#36

    It would be great if you check it and try to use it. We are very happy to get any feedback on it. Especially how to make it better.

  18. ShotaAk commented on Jan 6, 2021

    @ShotaAk
    ContributorAuthor

    @destogl That's great documentation!
    The contents of Differences to ros_control (ROS1) and Migration Guide to ros2_control are exactly what I wanted to read.
    Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bug

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions