SMACH concepts

The underlying core, SMACH, is lightweight with good logging and utility functions. It has two fundamental interfaces:

  • States: States are what you want the robot to exhibit as a behavior or simply execute an action. They have potential outcomes as a result of the execution of actions. In ROS, the behavior or actions are defined in the execute() function, which runs until it returns an identified outcome.
  • Containers: Containers are a collection of states. They implement an execution policy that can be hierarchical, execute more than one state at a time (concurrent), or execute the state for a certain period of time (iterative):

A simple state machine in ROS (source: http://wiki.ros.org/smach/Tutorials/Getting%20Started. Image from ros.org. Licensed under Creative Commons CC-BY-3.0: https://creativecommons.org/licenses/by/3.0/us/legalcode)

Let's consider the preceding diagram and look into SMACH concepts in a bit more detail.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.135.197.201