17 #include <std_msgs/String.h> 24 QNode(argc,argv,
"qlistener")
33 ROS_INFO(
"I heard: [%s]", msg->data.c_str());
35 std::stringstream logging_msg;
36 logging_msg <<
"[ INFO] [" <<
ros::Time::now() <<
"]: I heard: " << msg->data;
37 QVariant new_row(QString(logging_msg.str().c_str()));
43 std::cout <<
"Ros shutdown, proceeding to close the gui." << std::endl;
Subscriber subscribe(const std::string &topic, uint32_t queue_size, void(T::*fp)(M), T *obj, const TransportHints &transport_hints=TransportHints())
Ros communication central!
Listener(int argc, char **argv)
ros::Subscriber chatter_subscriber
void chatterCallback(const std_msgs::String::ConstPtr &msg)