Skip to Main Content Skip to Search
Product Documentation

Converting to and from Atomic Subcharts

Converting a State or Subchart to an Atomic Subchart

To convert a state or subchart to an atomic subchart, right-click the object in your chart and select Make Contents > Atomic Subcharted.

After you convert a state or subchart to an atomic subchart, local data appears as data store memory in the atomic subchart.

Scope of Data Before ConversionScope of Data After Conversion
InputInput
OutputOutput
Local Data store memory
ParameterParameter
ConstantConstant

An atomic subchart looks opaque like a regular subchart but includes the label (Atomic) in the upper-left corner. If you use a linked atomic subchart from a library, the label (Link) appears in the upper-left corner.

For example, the following model contains a chart, Air Controller, that uses an atomic subchart:

In the Air Controller chart, PowerOn is an atomic subchart, but PowerOff is a regular subchart:

Converting an Atomic Subchart to a State or Subchart

When an Atomic Subchart Is a Library Link

To convert a linked atomic subchart back to a state or subchart:

  1. Right-click the atomic subchart and select Link Options > Disable Link.

  2. Follow the steps in When an Atomic Subchart Is Not a Library Link.

When an Atomic Subchart Is Not a Library Link

To convert an atomic subchart back to...Follow these steps...

A state

  1. Right-click the atomic subchart in your chart and clear the Make Contents > Atomic Subcharted check box.

  2. Right-click the object again and clear the Make Contents > Subcharted check box.

    You might need to rearrange graphical objects in your chart after performing this step.

A regular subchart

  1. Right-click the atomic subchart in your chart and clear the Make Contents > Atomic Subcharted check box.

Restrictions for Converting an Atomic Subchart to a State or Subchart

In the following cases, converting an atomic subchart to a state or subchart does not work:

For more information, see Mapping Variables for Atomic Subcharts.

  


Free Stateflow Interactive Kit

Learn how engineers use Stateflow to model state machines in their Simulink models.


Get free kit

Trials Available

Try the latest version of Stateflow.


Get trial software
 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS