35 from actionlib.msg
import TestAction, TestFeedback, TestResult
41 action_spec = TestAction
42 ActionServer.__init__(
45 rospy.loginfo(
"Creating ActionServer [%s]\n", name)
52 rospy.loginfo(
"Got goal %d", int(goal.goal))
55 gh.set_succeeded(
None,
"The ref server has succeeded")
58 gh.set_aborted(
None,
"The ref server has aborted")
60 gh.set_rejected(
None,
"The ref server has rejected")
80 g.publish_feedback(TestFeedback(n-i))
87 g.set_succeeded(TestResult(n - i),
"The ref server has succeeded")
89 g.set_aborted(TestResult(n - i),
"The ref server has aborted")
99 if __name__ ==
"__main__":
100 rospy.init_node(
"ref_server")