Functional Description
Ever fancied taking an insightful and cultured excursion to Europe? A glamorous trek across North America? Perhaps an adventure to the tropical climes of the Far East? Well now you can! This application gives you an opportunity to all of these things... and learn a little about the LabVIEW State Machine Design Architecture in the process. This application is an example of the State Machine design architecture - each frame of the nested case-structure represents a different international city. Running the application allows you to embark on a Phileas Fogg style journey around the world.
(Disclaimer: I may have made the application sound a little more exciting than it really is.)
Caveats and Additional Notes
The ability to remain in certain locations and programmatically change the tour on the fly illustrates the flexibility of the State Machine design architecture. Standard sequential programming is far too rigid to implement an application as flexible as this one.
A FINAL NOTE: This application also illustrates a example of the use of a type definition. The code uses a enumerated control to decide which city (state) you will fly (transition) to next. Because the enumerated list of cities is a type definition, if you wanted to add a city to the world tour you could simply add a new item to the type definition (.ctl file). This modification will then propagate throughout your code. Without the use of the type def, you would have had to update every single use of the enumerated control on the block diagram. A monotonous and laborious task!!
Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.