Ros2, Robotics, AI, Computer Vision, Robots.
std::bind(&PublisherNode::callback, this)); } private: void callback() { std_msgs::msg::String message = std_msgs::msg::String(); message.data = "Hello, world! " + std::to_string(count_++); RCLCPP_INFO(this->get_logger(), "Publishing: '%s'", message.data.c_str()); // Publish the message