LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Wait until I press a "GO" button.

LabVIEW 6i
I'm developing a test tool that has to be sent all round the world with our test guys.
Some parameters have to be changed each time and then they have to run the application.
However these guys refuse to believe that they can't have an "OK" or "Start" button on the front panel to start the process and are unhappy with the "little white arrow" button of LabVIEW.

Please, someone, cure my headache!!

Some people have suggested a case statement with one case empty and the other with the code in but I can't get it to work.. my application just starts and then stops.

There must be a way to duplicate the LabVIEW run button ... but HOW??

Thanks in advance.
0 Kudos
Message 1 of 10
(19,154 Views)
Hi,
try to use attached example (you can find some details inside). If you do this, at least make your vi to autostart when is loaded - otherwise those guys will have to press two buttons in order to start the application.
If something unclear, email me at labviewer@yahoo.com.
Good luck!
Message 2 of 10
(19,154 Views)
I have improved the "Go Button" - example a little bit,
in case the application needs to be run not only once.
If something unclear, email me at werner.hasche@web.de
Regards.......
wha
Message 4 of 10
(19,154 Views)
Well done. Yet, I made it that way in order to answer strictly. Also, keep in mind that if you have a long running process, the STOP button behavior will be somehow confusing as long as you have to wait some time till the VI will be stopped.
0 Kudos
Message 5 of 10
(19,154 Views)
how would you stop? - in most cases I need to exit
a program in a proper way - means: switch off power-supplies or go back to start values if sweep of
parameters were made or leave critical situations
(this all is related to Lab-measurement of integrated
circuits) ......regards ......wha
0 Kudos
Message 7 of 10
(19,154 Views)
You're right. Most of the applications will need this. Wat I said was related to this main post ... JUST to start the VI/I don't know other details about his application.
Thanks for the input !
0 Kudos
Message 8 of 10
(19,154 Views)
Usually, I put my check for a "stop" button in a parallel while loop (parallel to the main program). Then the program is always checking to see if you want to stop. This allows for a stop and orderly shutdown at any point. If the main program wants to stop, it can programmatically "push" the stop button using references. I have quite a few programs with abort/stop buttons built this way.

Rob
0 Kudos
Message 9 of 10
(19,154 Views)
Put your process in the second frame of a sequence. In the first frame put
a while loop with a continue button (don't forget to put a wait x msec
function in it(set to 100)). Then set the vi properties to run when opened.

"brownjd77" wrote in message
news:5065000000080000006C2A0000-999158726000@exchange.ni.com...
> LabVIEW 6i
> I'm developing a test tool that has to be sent all round the world
> with our test guys.
> Some parameters have to be changed each time and then they have to run
> the application.
> However these guys refuse to believe that they can't have an "OK" or
> "Start" button on the front panel to start the process and are unhappy
> with the "little white arrow" button of LabVIEW.
>
> Please, someone, cure my headache!!
>
> Some peo
ple have suggested a case statement with one case empty and
> the other with the code in but I can't get it to work.. my application
> just starts and then stops.
>
> There must be a way to duplicate the LabVIEW run button ... but HOW??
>
> Thanks in advance.
0 Kudos
Message 3 of 10
(19,154 Views)
put your code in a true\false case with the start button in mechanical action: switch when pressed, and then put all this in a while loop with a Exit button to close your application.
0 Kudos
Message 6 of 10
(19,154 Views)
The answer is within the question. However; you will need to rephrase your question to answer it.

What I am speaking of is implementation. How you implement the solution is in how you want it implemented.

If you are running this in a development environment, which it seems as though you are, I would suggest one of two things: A) tell the test engineers (technicians?) to get with the program and learn how to run a LabVIEW VI or B)build this as an executable or make the VI function as an executable on the runtime engine without building it.

If this is one of many VIs that go out in the field for testing, you may wish to package them into a library or installation, and have a 'loader application' that loads them.

As you can see, the answer is much more complicated than the question. You see, the convenience of LabVIEW as a development environment means that most programmers put off learning how to implement their programs as finished products, and instead, continue to run them in the development enviornment. Believe me, this is all to common, and unfortunately, too convenient. However; the answer is a matter of practice and discipline. If this were a C++ program, you would not have any problems developing the finished product for implemention, and it would work as you wanted it, and as the field personnel expected it. However, you are able to run the program in a development environment, a convenience which is coming back to haunt you.

Go ahead and take that extra step and figure out how you want to implement this in the field. LabVIEW has the distinct advantage of allowing you to execute development level programs (VIs) in a runtime environment. Something not available in C/C++ (readily that is).

So, figure out what implementation you want, and design your finished product with that in mind.

On the VI level this means an execute button. Poll the desired control (start?) in a while loop with about a 250ms delay. When the button is pressed, the loop ends, and your code will begin (assuming you have wired the dataflow as such). Also, you have to decide how to launch the VI. If you want the user to simply be able to open it, then you need to build it as a complete application (using application builder). If you don't have the app builder, or want to be able to replace the VI with modified versions often, then create a loader. You will still have to build the application. I'm actually not sure how to use the runtime without a built application anymore.

Anyway, I hope this helps.

Good luck.
Message 10 of 10
(19,154 Views)