This example demonstrates how to build a State Machine controlling axis using SoftMotion Function Blocks.
NI SoftMotion 2009 introduced a new API based on LabVIEW function blocks. This is a non-blocking API optimized for use in real time targets like cRIO. This example shows users how these function blocks can be used in a state machine architecture for developing motion applications.
A key concept to remember when programming with function blocks is that the "execute" boolean input must transition from false-to-true in order for the function block to start. If a boolean true constant is wired to the execute input, the user will find that the first call of the function block executes correctly, but in every subsequent call it fails to start.
LabVIEW Full Development System 2012 (or compatible)
LabVIEW Real-Time Module 2012 (or compatible)
NI SoftMotion Module 2012 (or compatible)
NI-CompactRIO 12.0 (or compatible)
NI Real-Time cRIO
Steps to Implement or Execute Code
Run the VI.
Additional Information or References
**The code for this example has been edited to meet the new Community Example Style Guidelines. The edited copy is marked with the text 'NIVerified'. Read here for more information about the new Example Guidelines and Community Platform.**