vision_detect_outlet.py
Go to the documentation of this file.
00001 #!/usr/bin/env python
00002 # stub for outlet detection action
00003 
00004 import roslib; roslib.load_manifest('pr2_plugs_actions')
00005 import rospy;
00006 import actionlib;
00007 from pr2_common_action_msgs.msg import *
00008 from pr2_plugs_msgs.msg import *
00009 
00010 
00011 
00012 #server actionlib.simple_action_server.SimpleActionServer
00013 
00014 def execute_cb(goal):
00015   rospy.loginfo("Action server received goal")
00016 
00017   # return the prior as the result
00018   result = VisionOutletDetectionResult()
00019   result.outlet_pose = goal.prior
00020   result.outlet_pose = server.set_succeeded(result)
00021   
00022 
00023 
00024 if __name__ == '__main__':
00025   #Initialize the node
00026   name = 'vision_outlet_detection'
00027   rospy.init_node(name)
00028   server = actionlib.simple_action_server.SimpleActionServer(name, VisionOutletDetectionAction, execute_cb)
00029   rospy.loginfo('%s: Action server running', name)
00030   rospy.spin()


pr2_plugs_actions
Author(s): Jon Bohren, Patrick Mihelich, Wim Meeussen, and Melonee Wise
autogenerated on Thu Nov 28 2013 11:47:13