rosactionclient
Create ROS action client
Description
Use the rosactionclient to connect to an action server
            using a SimpleActionClient object and request the execution of action
            goals. You can get feedback on the execution process and cancel the goal at any time.
            The SimpleActionClient object encapsulates a simple action client and
            enables you to track a single goal at a time.
Creation
Syntax
Description
client = rosactionclient(actionname)ActionName. The
                        client determines the action type automatically. If the action is not
                        available, this function displays an error. 
Use rosactionclient to connect to an action server and
                        request the execution of action goals. You can get feedback on the execution
                        progress and cancel the goal at any time.
client = rosactionclient(actionname,actiontype)ActionType). If the action is not available, or
                        the name and type do not match, the function displays an error.
[
                        returns a goal message to send the action client created using any of the
                        arguments from the previous syntaxes. The client,goalMsg]
= rosactionclient(___)Goal message
                        is initialized with default values for that message.
If the ActionFcn, FeedbackFcn,
                        and ResultFcn callbacks are defined, they are called
                        when the goal is processing on the action server. All callbacks associated
                        with a previously sent goal are disabled, but the previous goal is not
                        canceled.
[___]
= rosactionclient(___,"DataFormat","struct")
                        uses message structures instead of objects. For more information, see ROS Message Structures.
client = ros.SimpleActionClient(node,actionname)node is the Node object that is connected to
                        the ROS network. The client determines the action type automatically. If the
                        action is not available, the function displays an error. 
client = ros.SimpleActionClient(node,actionname,actiontype)rosaction type
                            actionname
client =  ros.SimpleActionClient(___,"DataFormat","struct")
Properties
Object Functions
| cancelGoal | Cancel last goal sent by client | 
| cancelAllGoals | Cancel all goals on action server | 
| rosmessage | Create ROS messages | 
| sendGoal | Send goal message to action server | 
| sendGoalAndWait | Send goal message and wait for result | 
| waitForServer | Wait for action server to start | 
Examples
Limitations
- MATLAB® Compiler™ software do not support ROS custom messages and the - rosgenmsgfunction.
Extended Capabilities
Version History
Introduced in R2019bSee Also
rosactionserver | sendGoal | cancelGoal | waitForServer | rosmessage | rosaction