46 #include "robocluedo_msgs/GoTo.h"
47 #include "std_msgs/Empty.h"
51 #define SERVICE_GO_TO "/go_to"
52 #define PUBLISHER_HINT_SIGNAL "/hint_signal"
54 #define OUTLABEL "[cluedo_movement_controller]"
55 #define OUTLOG std::cout << OUTLABEL << " "
56 #define LOGSQUARE( str ) "[" << str << "] "
61 ros::Publisher* pub_hint_signal;
79 bool GoToCallback( robocluedo_msgs::GoTo::Request& where, robocluedo_msgs::GoTo::Response& success )
82 (ros::Duration(1)).sleep();
83 ROS_INFO(
"%s position reached -> %s",
OUTLABEL, where.where.c_str() );
86 ROS_INFO(
"%s issuing signal to the Oracle...",
OUTLABEL );
87 pub_hint_signal->publish( std_msgs::Empty( ) );
90 success.success =
true;
104 int main(
int argc,
char* argv[] )
106 ros::init( argc, argv,
"cluedo_movement_controller" );
118 pub_hint_signal = &pub;
121 OUTLOG <<
"ready!" << std::endl;