stderr.log 5.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. In file included from /home/wub/work/1_nzzn/2_code/13_LG/src/Drive/g29_ros2_feedback_drive/src/g29_ros2_feedback/src/joystick.cpp:34:
  2. /home/wub/work/1_nzzn/2_code/13_LG/src/Drive/g29_ros2_feedback_drive/src/g29_ros2_feedback/src/joystick.h: In constructor ‘Joystick_pub::Joystick_pub(const string&, const string&)’:
  3. /home/wub/work/1_nzzn/2_code/13_LG/src/Drive/g29_ros2_feedback_drive/src/g29_ros2_feedback/src/joystick.h:56:17: warning: ‘Joystick_pub::filename’ will be initialized after []8;;https://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html#index-Wreorder-Wreorder]8;;]
  4. 56 | std::string filename; // 设备文件名
  5. | ^~~~~~~~
  6. /home/wub/work/1_nzzn/2_code/13_LG/src/Drive/g29_ros2_feedback_drive/src/g29_ros2_feedback/src/joystick.cpp:40:41: warning:  base ‘rclcpp::Node’ []8;;https://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html#index-Wreorder-Wreorder]8;;]
  7. 40 | : filename(filename), Node(node_name) // 初始化成员变量 filename
  8. | ^
  9. /home/wub/work/1_nzzn/2_code/13_LG/src/Drive/g29_ros2_feedback_drive/src/g29_ros2_feedback/src/joystick.cpp:39:1: warning:  when initialized here []8;;https://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html#index-Wreorder-Wreorder]8;;]
  10. 39 | Joystick_pub::Joystick_pub(const std::string &filename, const std::string &node_name)
  11. | ^~~~~~~~~~~~
  12. /home/wub/work/1_nzzn/2_code/13_LG/src/Drive/g29_ros2_feedback_drive/src/g29_ros2_feedback/src/joystick.cpp:91:62: error: ‘joy’ is not a member of ‘sensor_msgs::msg’; did you mean ‘Joy’?
  13. 91 | g29_publisher = this->create_publisher<sensor_msgs::msg::joy>("g29_feedback", 10);
  14. | ^~~
  15. | Joy
  16. /home/wub/work/1_nzzn/2_code/13_LG/src/Drive/g29_ros2_feedback_drive/src/g29_ros2_feedback/src/joystick.cpp:91:66: error: no matching function for call to ‘Joystick_pub::create_publisher<<expression error> >(const char [13], int)’
  17. 91 | 29_publisher = this->create_publisher<sensor_msgs::msg::joy>("g29_feedback", 10);
  18. | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~
  19. In file included from /opt/ros/humble/include/rclcpp/rclcpp/executors/single_threaded_executor.hpp:28,
  20. from /opt/ros/humble/include/rclcpp/rclcpp/executors.hpp:22,
  21. from /opt/ros/humble/include/rclcpp/rclcpp/rclcpp.hpp:155,
  22. from /home/wub/work/1_nzzn/2_code/13_LG/src/Drive/g29_ros2_feedback_drive/src/g29_ros2_feedback/src/joystick.h:25,
  23. from /home/wub/work/1_nzzn/2_code/13_LG/src/Drive/g29_ros2_feedback_drive/src/g29_ros2_feedback/src/joystick.cpp:34:
  24. /opt/ros/humble/include/rclcpp/rclcpp/node.hpp:195:3: note: candidate: ‘template<class MessageT, class AllocatorT, class PublisherT> std::shared_ptr<PublisherT> rclcpp::Node::create_publisher(const string&, const rclcpp::QoS&, const rclcpp::PublisherOptionsWithAllocator<AllocatorT>&)’
  25. 195 | create_publisher(
  26. | ^~~~~~~~~~~~~~~~
  27. /opt/ros/humble/include/rclcpp/rclcpp/node.hpp:195:3: note:  template argument deduction/substitution failed:
  28. /home/wub/work/1_nzzn/2_code/13_LG/src/Drive/g29_ros2_feedback_drive/src/g29_ros2_feedback/src/joystick.cpp:91:66: error: template argument 1 is invalid
  29. 91 | 29_publisher = this->create_publisher<sensor_msgs::msg::joy>("g29_feedback", 10);
  30. | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~
  31. /home/wub/work/1_nzzn/2_code/13_LG/src/Drive/g29_ros2_feedback_drive/src/g29_ros2_feedback/src/joystick.cpp: In member function ‘void Joystick_pub::publish()’:
  32. /home/wub/work/1_nzzn/2_code/13_LG/src/Drive/g29_ros2_feedback_drive/src/g29_ros2_feedback/src/joystick.cpp:159:38: error: ‘joy’ is not a member of ‘sensor_msgs::msg’; did you mean ‘Joy’?
  33. 159 | auto message = sensor_msgs::msg::joy();
  34. | ^~~
  35. | Joy
  36. gmake[2]: *** [CMakeFiles/g29_ros2_feedback_node.dir/build.make:90:CMakeFiles/g29_ros2_feedback_node.dir/src/joystick.cpp.o] 错误 1
  37. gmake[1]: *** [CMakeFiles/Makefile2:137:CMakeFiles/g29_ros2_feedback_node.dir/all] 错误 2
  38. gmake: *** [Makefile:146:all] 错误 2