Company Events Academic Community Support Solutions Products & Services Contact NI MyNI

Single-Stepping through a Statechart (Statechart Module)

LabVIEW 2010 Statechart Module Help

Edition Date: June 2013

Part Number: 372103F-01

»View Product Info
Download Help (Windows Only)

Single-stepping through a statechart works similarly to single-stepping through a VI. You can single-step through a statechart only when the Pause button , located on the toolbar of the Statechart Debugging window, is red. This button turns red after the statechart reaches a breakpoint you placed. This button also turns red after you click the button, which means you can pause the statechart and begin single-stepping at any time.

Tip  You can start a statechart in single-stepping mode by clicking the Pause button before running the caller VI.

Complete the following steps to single-step through a statechart:

  1. Run the caller VI.
  2. Right-click the Run Statechart function and select Debug Statechart. The statechart diagram appears in debugging mode, which means you cannot edit the diagram.
    Note  If you do not see the Debug Statechart option, you might have disabled statechart debugging. You must re-enable debugging and re-generate the code before proceeding.
  3. Run the statechart until the statechart pauses at a breakpoint or until you click the Pause button.
  4. Click one of the following buttons:

     Step Into—Executes the next transition or state action and then pauses, regardless of where that transition or state is in the statechart hierarchy. Use this button to step through an entire statechart hierarchy while pausing at each action.

     Step Over—Executes the next transition or state action and then pauses at the next transition or state that is at the same statechart hierarchy level. This behavior means that the Step Over button does not pause before executing substates of the current superstate. Conversely, the Step In button does pause in these situations. Use the Step Over button to step through an entire statechart hierarchy without pausing at substate actions.

     Step Out—Finishes executing the current transition or state action, returns to the superstate, and then pauses. Use this button to return to a superstate after having stepped into the substate(s) of that superstate.


 Was this document helpful?  submit
  Helpful Not Helpful