Go to the documentation of this file.00001
00002
00003 import sys
00004
00005 import roslib; roslib.load_manifest('wouse')
00006 import rospy
00007 from wouse.srv import WouseRunStop, WouseRunStopRequest
00008
00009 rospy.init_node('wouse_reset')
00010 try:
00011 rospy.wait_for_service('/wouse_run_stop', 10)
00012 reset_client = rospy.ServiceProxy('wouse_run_stop', WouseRunStop)
00013 rospy.loginfo("[Wouse Reset]: Found wouse run stop service.")
00014 except:
00015 rospy.logwarn("[Wouse Reset]: Could not find wouse run stop service.")
00016 sys.exit()
00017
00018 req = WouseRunStopRequest()
00019 req.start = True
00020 success = reset_client(req)
00021
00022 if success:
00023 rospy.loginfo("[Wouse Reset]: Reset returned successfully.")
00024 else:
00025 rospy.logwarn("[Wouse Reset]: Reset reported failure.")
00026
00027