electric:Documentation generated on March 01, 2013 at 03:25 PM
fuerte:Documentation generated on March 05, 2013 at 01:11 PM
groovy:Documentation generated on October 05, 2014 at 11:55 PM
hydro:Only showing information from the released package extracted on September 16, 2015 at 10:00 AM. No API documentation available. Please see this page for information on how to submit your repository to our index.
indigo:Documentation generated on June 07, 2019 at 04:29 AM (doc job).
jade:Documentation generated on June 11, 2017 at 10:32 AM (doc job).
kinetic:Documentation generated on June 10, 2019 at 09:06 PM (doc job).
lunar:Documentation generated on June 06, 2019 at 06:06 AM (doc job).
melodic:Documentation generated on March 01, 2022 at 06:15 AM (doc job).
noetic:Documentation generated on March 02, 2022 at 08:13 AM (doc job).
SMACH is useful when you want a robot to execute some complex plan, where all possible states and state transitions can be described explicitly. This basically takes the hacking out of hacking together different modules to make systems like mobile robotic manipulators do interesting things.
Fast prototyping: The straightforward Python-based SMACH syntax makes it easy to quickly prototype a state machine and start running it.
Complex state machines: SMACH allows you to design, maintain and debug large, complex hierarchical state machines. You can find an example of a complex hierarchical state machine here.
Introspection: SMACH gives you full introspection in your state machines, state transitions, data flow, etc. See the smach_viewer for more details.
When should I NOT use SMACH?
Unstructured tasks: SMACH will fall short as the scheduling of your task becomes less structured.
Low-level systems: SMACH is not meant to be used as a state machine for low-level systems that require high efficiency, SMACH is a task-level architecture.
Smash: Do not use SMACH when you want to smash something, for that use smash.
Is SMACH only a finite state machine library?
You can build a finite state machine using SMACH, but SMACH can do much more. SMACH is a library for task-level execution and coordination, and provides several types of "state containers". One such container, is a finite state machine, but this container can also be a state in another container. See the tutorials page for a list of containers and states built into SMACH.
Documentation
The documentation page provides an overview of the concepts used in SMACH.
The tutorials page contains an extensive set of tutorials to get you up to speed building and running your own state machines.
Additional State Types
See AdditionalStateTypes for SMACH state classes with a variety of additional behaviors.
Examples
On the tutorials page you can find a number of easy examples. But if you are looking for some 'real' examples running SMACH: