29 #include "roscpp_tutorials/TwoInts.h" 33 int main(
int argc,
char **argv)
35 ros::init(argc, argv,
"add_two_ints_client");
38 ROS_INFO(
"usage: add_two_ints_client X Y");
44 roscpp_tutorials::TwoInts srv;
45 srv.request.a = atoi(argv[1]);
46 srv.request.b = atoi(argv[2]);
49 ROS_INFO(
"Sum: %ld", (
long int)srv.response.sum);
53 ROS_ERROR(
"Failed to call service add_two_ints");
ServiceClient serviceClient(const std::string &service_name, bool persistent=false, const M_string &header_values=M_string())
ROSCPP_DECL void init(int &argc, char **argv, const std::string &name, uint32_t options=0)
bool call(MReq &req, MRes &res)
int main(int argc, char **argv)