05-07-2008 02:48 PM
05-07-2008 03:07 PM - edited 05-07-2008 03:08 PM
I'm a little confused by your description. You say you are reading a load cell from the board. What voltage are you writing to the board and why? Please post some code.
If you want labview to stop, you just need to wire a stop condition to the stop terminal of the while loop that surrounds your code.
05-07-2008 03:35 PM
12-10-2011 03:55 PM - edited 12-10-2011 03:55 PM
I just noticed there is an error in the 2nd post. The current time + 10000 (this is in sec not ms). Thanks!
12-11-2011 01:38 PM - edited 12-11-2011 01:39 PM
@bmira1 wrote:
I would like to ouptut the voltage to stop after a certain amount of time with the load still on the load cell.
Of course stopping LabVIEW (as described in the post title) and stopping an output voltage (as described in the post body) are two completely different things! Blindly stopping LabVIEW will not necessarily reset any active analog output to zero.
Best would be a simple state machine that changes the output to zero after a certain elapsed time. This could for example be done with the timeout case of an event structure or even with the "elapsed time" express VI (or with the code fragments given above after you make sure there is a small wait in the polling loop)
When the experiment starts, write a certain voltage to the output once (You don't need to do that over and over, only when the voltage changes) and, after the time has elapsed, write a zero voltage to the output.
No need to stop LabVIEW. You should actually disable or catch "panel close?" events and other abnormal shutdown attempts, and reset the outputs in an orderly fashion before allowing the program to stop.