LabVIEW 2010 Statechart Module Help
»View Product Info
You can set breakpoints on a statechart diagram or in a guard or action. The following sections provide information about setting breakpoints in both of these locations.
Setting Breakpoints on a Statechart Diagram
Complete the following steps to set a breakpoint on a statechart diagram.
- Run the caller VI.
- 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.
- Right-click any transition node or state and select Breakpoint»Set Breakpoint from the shortcut menu. LabVIEW highlights the selected object in red.
When you reach a breakpoint during execution, the statechart pauses. You can take the following actions:
- Right-click the object and use the shortcut menu to display the guards and/or actions of that object.
Single-step through execution by using the single-stepping buttons.
- Click the Pause button to continue running until the next breakpoint or until the statechart finishes executing.
Setting Breakpoints in a Guard or Action
You can set breakpoints in a guard or action by right-clicking an object on the block diagram and selecting Breakpoint»Set Breakpoint from the shortcut menu. When an executing statechart encounters these breakpoints, LabVIEW pauses execution, and you can debug the guard or action similar to debugging a VI.