08-20-2008 12:29 PM
08-20-2008 01:28 PM
08-20-2008 01:36 PM
08-20-2008 02:01 PM
08-20-2008 02:51 PM
08-20-2008 02:56 PM
08-20-2008 04:09 PM
Your problem is that you are trying to read the menu using the Get Menu Selection function and you also have an event structure. The event structure has registered the event of the user selecting a menu item. Thus, it will prevent the Get Menu Selection function from working.
You also seem to be trying to mash together a standard producer-consumer architecture into a single loop. This usually doesn't work out too well. Also, you should not use the Stop function to stop your VI. You should program it so that a graceful exit is performed.
08-20-2008 06:49 PM
Hi Superseadragon,
I recommend you to use an event-driven state machine desing pattern that combines a queued state machine and event structure into a hybrid single-loop design pattern.
I made an example with your code but as I don't have your set up I put in commentary all the communication function.
To close the VI click on the cross on the upper right corner like for a tradionnal application.
You can fire an event from the run time menu. I included a case in the event structure. Have a look at it. This is not the only way to do it.
Have fun with your algae!
Charly
08-25-2008 10:54 AM
Charly,
Thanks for the help. It seems that I still have a bit to learn here. I get what you were doing and I like it. The event structure seems to work a lot better the menu actions. I think the event structure may even slim the program up a bit. Thanks again!!