void MyFunc(const std_msgs::String::ConstPtr& msg)
{
//code
}
....
ros::Subscriber sub = n.subscribe("shatter", 1000, chatterCallback);
standard subscription and reading data from the theme. But I have a question is it possible to implement reading from another topic that the message was in the same main function
↧