kroshu / kuka_drivers

Repository containing ROS2 drivers for multiple KUKA robots
Apache License 2.0
77 stars 23 forks source link

[BUG] - Workspace build errors, ROS2 jazzy #169

Closed matthias88 closed 4 months ago

matthias88 commented 5 months ago

Description

Hi,

i can't build kuka_drivers rolling or master branch via colcon build on Ubuntu 24.04 with ROS2 jazzy (docker). I get the following build errors, see attached logs. Can anybody help me to fix this issues?

KUKA robot OS

KSS

KUKA robot OS version

KSS 8.5.8

KUKA external interface version

RSI 4.0.9

Affected robot model(s)

KR6 R700-2

Version or commit hash of the driver

No response

Setup

docker pull osrf/ros:jazzy-desktop-full-noble
docker run -it --net=host --ipc=host --privileged --env="DISPLAY" --env="QT_X11_NO_MITSHM=1" --volume="/tmp/.X11-unix:/tmp/.X11-unix:rw" --volume="${XAUTHORITY}:/root/.Xauthority" --volume="/dev/input" osrf/ros:jazzy-desktop-full-noble

Build Moveit2 from source according to: https://moveit.picknik.ai/main/doc/tutorials/getting_started/getting_started.html 

Build kuka drivers from source according to: https://github.com/kroshu/kuka_drivers

Reproduction steps

I just followed the step-by-step instructions provided on the Kroshu GitHub readme

Logs

root@ROBTR-CA01:/home/xyz/ws_xyz# colcon build
Starting >>> moveit_common
Starting >>> moveit_msgs
Starting >>> moveit_configs_utils
Starting >>> moveit_resources_panda_description
Starting >>> kuka_resources
Starting >>> kuka_drivers_core
Starting >>> moveit_resources_fanuc_description
Starting >>> kuka_driver_interfaces
Starting >>> kuka_external_control_sdk
Starting >>> rviz_visual_tools
Starting >>> kuka_mock_hardware_interface
Starting >>> moveit_resources_pr2_description
Starting >>> moveit_resources_prbt_support
Starting >>> kuka_rsi_simulator
Starting >>> serial
Starting >>> robotiq_controllers
Starting >>> robotiq_description                                                                                                                                                     
Finished <<< moveit_resources_fanuc_description [0.85s]                                                                                                                                          
Starting >>> moveit_resources_fanuc_moveit_config
Finished <<< moveit_common [0.90s]                                                                                                                                                 
Starting >>> rviz_marker_tools
Finished <<< kuka_resources [0.93s]
Finished <<< moveit_resources_panda_description [0.97s]
Starting >>> moveit_resources_panda_moveit_config
Starting >>> kuka_lbr_iisy_support                                                                                                                                     
Starting >>> kuka_lbr_iiwa_support
Starting >>> kuka_agilus_support
Finished <<< moveit_resources_pr2_description [1.06s]                                                                                                                  
Starting >>> kuka_cybertech_support
Finished <<< moveit_resources_prbt_support [1.13s]                                                                                                                     
Starting >>> kuka_fortec_support
Finished <<< robotiq_description [2.14s]                                                                                                                                   
Starting >>> kuka_iontec_support
Finished <<< serial [2.65s]                                                                                                                                                    
Starting >>> kuka_quantec_support
Finished <<< kuka_mock_hardware_interface [2.72s]
Finished <<< kuka_lbr_iisy_support [1.78s]
Starting >>> robotiq_driver                                                                                                                                                     
Finished <<< moveit_resources_panda_moveit_config [1.88s]
Finished <<< kuka_rsi_simulator [2.79s]
Finished <<< robotiq_controllers [2.78s]
Starting >>> dual_arm_panda_moveit_config
Finished <<< moveit_configs_utils [2.98s]                                                                                                                                       
Finished <<< kuka_cybertech_support [1.90s]                                                                                                                                                     
Finished <<< moveit_resources_fanuc_moveit_config [2.19s]
Starting >>> moveit_resources
Finished <<< kuka_agilus_support [2.06s]                                                                                                                                                        
Finished <<< kuka_fortec_support [1.92s]
Finished <<< kuka_lbr_iiwa_support [2.14s]
Finished <<< rviz_marker_tools [2.32s]                                                                                                                                                          
Finished <<< kuka_iontec_support [1.29s]                                                                                                                                                        
Finished <<< kuka_driver_interfaces [3.60s]                                                                                                                                                  
Finished <<< dual_arm_panda_moveit_config [0.78s]
Finished <<< kuka_quantec_support [1.00s]                                                                                                                                                
Finished <<< moveit_resources [0.68s]
Finished <<< rviz_visual_tools [4.04s]                                                                                                                                                    
Finished <<< robotiq_driver [1.65s]                                                                                                                                                                       
Starting >>> robotiq_hardware_tests
Finished <<< robotiq_hardware_tests [0.79s]
--- stderr: kuka_drivers_core                                                                                                                        
In file included from /home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/controller_handler.hpp:24,
                 from /home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:18:
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/control_mode.hpp:23:6: warning: elaborated-type-specifier for a scoped enum must not use the ‘class’ keyword
   23 | enum class ControlMode : std::uint8_t
      | ~~~~ ^~~~~
      |      -----
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/control_mode.hpp:23:12: error: use of enum ‘ControlMode’ without previous declaration
   23 | enum class ControlMode : std::uint8_t
      |            ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/control_mode.hpp:23:24: error: expected unqualified-id before ‘:’ token
   23 | enum class ControlMode : std::uint8_t
      |                        ^
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/control_mode.hpp:39:6: warning: elaborated-type-specifier for a scoped enum must not use the ‘class’ keyword
   39 | enum class ControllerType : std::uint8_t
      | ~~~~ ^~~~~
      |      -----
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/control_mode.hpp:39:12: error: use of enum ‘ControllerType’ without previous declaration
   39 | enum class ControllerType : std::uint8_t
      |            ^~~~~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/control_mode.hpp:39:27: error: expected unqualified-id before ‘:’ token
   39 | enum class ControllerType : std::uint8_t
      |                           ^
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/controller_handler.hpp:71:12: error: ‘ControlMode’ was not declared in this scope
   71 |   std::map<ControlMode, ControllerTypes> control_mode_map_;
      |            ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/controller_handler.hpp:71:40: error: template argument 1 is invalid
   71 |   std::map<ControlMode, ControllerTypes> control_mode_map_;
      |                                        ^
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/controller_handler.hpp:71:40: error: template argument 3 is invalid
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/controller_handler.hpp:71:40: error: template argument 4 is invalid
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/controller_handler.hpp:96:11: error: ‘ControllerType’ does not name a type; did you mean ‘ControllerTypes’?
   96 |     const ControllerType controller_type, const std::string & controller_name);
      |           ^~~~~~~~~~~~~~
      |           ControllerTypes
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/controller_handler.hpp:109:5: error: ‘ControlMode’ has not been declared
  109 |     ControlMode new_control_mode);
      |     ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/include/kuka_drivers_core/controller_handler.hpp:130:50: error: ‘ControlMode’ has not been declared
  130 |   std::vector<std::string> GetControllersForMode(ControlMode control_mode);
      |                                                  ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:28:9: error: ‘ControllerType’ does not name a type; did you mean ‘ControllerTypes’?
   28 |   const ControllerType controller_type, const std::string & controller_name)
      |         ^~~~~~~~~~~~~~
      |         ControllerTypes
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp: In member function ‘bool kuka_drivers_core::ControllerHandler::UpdateControllerName(int, const std::string&)’:
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:32:10: error: ‘ControllerType’ has not been declared
   32 |     case ControllerType::JOINT_POSITION_CONTROLLER_TYPE:
      |          ^~~~~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:33:25: error: ‘ControlMode’ has not been declared
   33 |       control_mode_map_[ControlMode::JOINT_POSITION_CONTROL].standard_controller = controller_name;
      |                         ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:34:25: error: ‘ControlMode’ has not been declared
   34 |       control_mode_map_[ControlMode::JOINT_IMPEDANCE_CONTROL].standard_controller = controller_name;
      |                         ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:36:10: error: ‘ControllerType’ has not been declared
   36 |     case ControllerType::CARTESIAN_POSITION_CONTROLLER_TYPE:
      |          ^~~~~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:37:25: error: ‘ControlMode’ has not been declared
   37 |       control_mode_map_[ControlMode::CARTESIAN_POSITION_CONTROL].standard_controller =
      |                         ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:39:25: error: ‘ControlMode’ has not been declared
   39 |       control_mode_map_[ControlMode::CARTESIAN_IMPEDANCE_CONTROL].standard_controller =
      |                         ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:42:10: error: ‘ControllerType’ has not been declared
   42 |     case ControllerType::JOINT_VELOCITY_CONTROLLER_TYPE:
      |          ^~~~~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:43:25: error: ‘ControlMode’ has not been declared
   43 |       control_mode_map_[ControlMode::JOINT_VELOCITY_CONTROL].standard_controller = controller_name;
      |                         ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:45:10: error: ‘ControllerType’ has not been declared
   45 |     case ControllerType::TWIST_CONTROLLER_TYPE:
      |          ^~~~~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:46:25: error: ‘ControlMode’ has not been declared
   46 |       control_mode_map_[ControlMode::CARTESIAN_VELOCITY_CONTROL].standard_controller =
      |                         ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:49:10: error: ‘ControllerType’ has not been declared
   49 |     case ControllerType::JOINT_IMPEDANCE_CONTROLLER_TYPE:
      |          ^~~~~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:50:25: error: ‘ControlMode’ has not been declared
   50 |       control_mode_map_[ControlMode::JOINT_IMPEDANCE_CONTROL].impedance_controller =
      |                         ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:53:10: error: ‘ControllerType’ has not been declared
   53 |     case ControllerType::CARTESIAN_IMPEDANCE_CONTROLLER_TYPE:
      |          ^~~~~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:54:25: error: ‘ControlMode’ has not been declared
   54 |       control_mode_map_[ControlMode::CARTESIAN_IMPEDANCE_CONTROL].impedance_controller =
      |                         ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:57:10: error: ‘ControllerType’ has not been declared
   57 |     case ControllerType::TORQUE_CONTROLLER_TYPE:
      |          ^~~~~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:58:25: error: ‘ControlMode’ has not been declared
   58 |       control_mode_map_[ControlMode::JOINT_TORQUE_CONTROL].standard_controller = controller_name;
      |                         ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:60:10: error: ‘ControllerType’ has not been declared
   60 |     case ControllerType::WRENCH_CONTROLLER_TYPE:
      |          ^~~~~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:61:25: error: ‘ControlMode’ has not been declared
   61 |       control_mode_map_[ControlMode::WRENCH_CONTROL].standard_controller = controller_name;
      |                         ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp: At global scope:
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:71:1: error: ‘std::pair<std::vector<std::__cxx11::basic_string<char>, std::allocator<std::__cxx11::basic_string<char> > >, std::vector<std::__cxx11::basic_string<char>, std::allocator<std::__cxx11::basic_string<char> > > > kuka_drivers_core::ControllerHandler::GetControllersForSwitch’ is not a static data member of ‘class kuka_drivers_core::ControllerHandler’
   71 | ControllerHandler::GetControllersForSwitch(ControlMode new_control_mode)
      | ^~~~~~~~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:71:44: error: ‘ControlMode’ was not declared in this scope
   71 | ControllerHandler::GetControllersForSwitch(ControlMode new_control_mode)
      |                                            ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:72:1: error: expected ‘,’ or ‘;’ before ‘{’ token
   72 | {
      | ^
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:152:26: error: ‘std::vector<std::__cxx11::basic_string<char>, std::allocator<std::__cxx11::basic_string<char> > > kuka_drivers_core::ControllerHandler::GetControllersForMode’ is not a static data member of ‘class kuka_drivers_core::ControllerHandler’
  152 | std::vector<std::string> ControllerHandler::GetControllersForMode(ControlMode control_mode)
      |                          ^~~~~~~~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:152:67: error: ‘ControlMode’ was not declared in this scope
  152 | std::vector<std::string> ControllerHandler::GetControllersForMode(ControlMode control_mode)
      |                                                                   ^~~~~~~~~~~
/home/xyz/ws_xyz/src/kuka_drivers/kuka_drivers_core/src/controller_handler.cpp:153:1: error: expected ‘,’ or ‘;’ before ‘{’ token
  153 | {
      | ^
gmake[2]: *** [CMakeFiles/kuka_drivers_core.dir/build.make:118: CMakeFiles/kuka_drivers_core.dir/src/controller_handler.cpp.o] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:141: CMakeFiles/kuka_drivers_core.dir/all] Error 2
gmake: *** [Makefile:146: all] Error 2
---
Failed   <<< kuka_drivers_core [5.41s, exited with code 2]
Aborted  <<< moveit_msgs [6.04s]                                                                                           
Aborted  <<< kuka_external_control_sdk [9.15s]                                 

Summary: 30 packages finished [9.46s]
  1 package failed: kuka_drivers_core
  2 packages aborted: kuka_external_control_sdk moveit_msgs
  1 package had stderr output: kuka_drivers_core
  61 packages not processed
Svastits commented 4 months ago

Hi, unfortunately currently we only support ROS 2 humble. The rolling branch will be always for the newest LTS release, but we still need some time to adapt to jazzy