class ControlMode(State): def __init__(self, mode): State.__init__(self, outcomes=['success']) self.mode = mode self.control_mode = ControllerMode() def execute(self, userdata): # change control mode self.control_mode.change_control_mode_client(self.mode) return 'success'
class ControlMode(State): def __init__(self, mode): State.__init__(self, ['succeeded', 'aborted', 'preempted']) self.mode = mode self.control_mode = ControllerMode() def execute(self, userdata): # change control mode self.control_mode.change_control_mode_client(self.mode) rospy.loginfo('changed DP control mode to: ' + str(self.mode) + '!') return 'succeeded'
def __init__(self, mode): State.__init__(self, ['succeeded', 'aborted', 'preempted']) self.mode = mode self.control_mode = ControllerMode()
def __init__(self, mode): State.__init__(self, outcomes=['success']) self.mode = mode self.control_mode = ControllerMode()