client.py
Go to the documentation of this file.
1 #!/usr/bin/env python
2 
3 """
4 Sample code to use with ServiceClient.pde
5 """
6 
7 import roslib; roslib.load_manifest("rosserial_arduino")
8 import rospy
9 
10 from rosserial_arduino.srv import *
11 
12 def callback(req):
13  print "The arduino is calling! Please send it a message:"
14  t = TestResponse()
15  t.output = raw_input()
16  return t
17 
18 rospy.init_node("service_client_test")
19 rospy.Service("test_srv", Test, callback)
20 rospy.spin()
def callback(req)
Definition: client.py:12


rosserial_arduino
Author(s): Michael Ferguson, Adam Stambler
autogenerated on Fri Jun 7 2019 22:02:56