ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Here is the solution found by @Lorenz and fixed (in the documentation) by @dirk-thomas.

An explicit type cast is required in front of the callback function:

Instead of: handle.advertise<std_msgs::Empty>("my_topic", 1, connectCallback);

Use: handle.advertise<std_msgs::Empty>("my_topic", 1, (ros::SubscriberStatusCallback)connectCallback);

Here is the solution found by @Lorenz and fixed (in the documentation) by @dirk-thomas.@Dirk Thomas.

An explicit type cast is required in front of the callback function:

Instead of: handle.advertise<std_msgs::Empty>("my_topic", 1, connectCallback);

Use: handle.advertise<std_msgs::Empty>("my_topic", 1, (ros::SubscriberStatusCallback)connectCallback);