LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Stripchart program voltage versus time help

The purpose of this program is to record voltage over an amount of time in order to replace a traditional strip chart recorder.  This program functions well except for a few small bugs.  Firstly, the time on the table does not reset when the program is paused through the Start/Stop Boolean.  I know what causes this problem, however I have not been able to find an adequate solution. In addition, the table flickers and flashes when the program is paused.  I know that this is caused by the table constantly refreshing, however I do not know the best way to fix this.  I have attached my VI and was hoping that I could get some suggestions, ideas, or fixes.  Thanks.
0 Kudos
Message 1 of 5
(2,896 Views)
Message Edited by Vincent DelMonte on 06-15-2010 03:43 PM
0 Kudos
Message 2 of 5
(2,878 Views)

Vincent DelMonte wrote:
The purpose of this program is to record voltage over an amount of time in order to replace a traditional strip chart recorder.  This program functions well except for a few small bugs.  Firstly, the time on the table does not reset when the program is paused through the Start/Stop Boolean.  I know what causes this problem, however I have not been able to find an adequate solution.

You need to reset the offset when you start plotting again. Take a look at the "Real-Time Chart" VI that ships with LabVIEW. 

 


In addition, the table flickers and flashes when the program is paused.  I know that this is caused by the table constantly refreshing, however I do not know the best way to fix this. 

Only update the table if you're actually collecting data. In other words, place the table update inside the main case structure. If you're not collecting data, what's the point of updating the table? Note that this means you'll need to place the save to file in there as well. 

 

 

Other comments:

  • The Write to Spreadsheet File has no path input. This is BAD. This means it will ask you for a filename EVERY TIME IT RUNS. Either provide a front panel path control, or use a shift register that's initialized by a front panel path control. If the path is left empty, then the Write to Spreadsheet File will ask for a filename the first time, and return the name of the file that was chosen. You can use this output as the value for the shift register terminal to go into the next iteration so you "save" the filename. 
  • You probably want to transpose the 2D array that's being fed to the Write to Spreadsheet File VI (you can use the "transpose" input of that VI).
  • You do not have a Stop button wired to your loop control. Do not use the Abort button in the toolbar. Let me repeat that in case you didn't read it the first time. DO NOT USE THE ABORT BUTTON IN THE TOOLBAR.
Message 3 of 5
(2,864 Views)

Thank you for the input, the only comment I have has to do with one of your suggestions.

 

 


@smercurio_fc wrote:

You need to reset the offset when you start plotting again. Take a look at the "Real-Time Chart" VI that ships with LabVIEW. 

 

 Only update the table if you're actually collecting data. In other words, place the table update inside the main case structure. If you're not collecting data, what's the point of updating the table? Note that this means you'll need to place the save to file in there as well. 


 

The reason that we are encountering our problems is because we have case structures.  If we put the save folder inside the case structure, then when the case structure is false, there is no way that we can save the data.  I was wondering if there is a better way of approaching solving the problem, or if using case structures was the best option, and if so, how we should tweak our program. 

 

Thank You 

0 Kudos
Message 4 of 5
(2,848 Views)

Well, if you are not acquiring data, what is there to save? If you do want to save, there is absolutely no reason you have to connect the write to file function to the output of the table. You can connect it to the daq data.

0 Kudos
Message 5 of 5
(2,838 Views)