LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Fast Voltage Data Acquisition and Logging

I have been experimenting with Labview to create a VI that can record and log voltages for several analog in channels.  I am using a DAQ 9171 with a NI 9223 module to record with my VI at a sample rate of 500 samples a second.  My problem is I acquire the data at inconsistent intervals and not the intervals of my sample rate.  If anyone has some knowledge or an example, they can dole upon me it would be much appreciated.

Download All
0 Kudos
Message 1 of 8
(137 Views)

You don't need to do timing in your loop, your samples are already timed by the sample clock. 

______________________________________________________________
Have a pleasant day and be sure to learn Python for success and prosperity.
0 Kudos
Message 2 of 8
(124 Views)

Try this and the dt is built into the reading: 

 

Jay14159265_0-1740094925520.png

 

______________________________________________________________
Have a pleasant day and be sure to learn Python for success and prosperity.
0 Kudos
Message 3 of 8
(120 Views)

TIme addition.PNGI can get the dt component of the waveform but I cannot get the right elapsed time in my .csv right.  It only writes a value of 1 for every time value in the column.

0 Kudos
Message 4 of 8
(55 Views)
0 Kudos
Message 5 of 8
(54 Views)

@DePeppers wrote:

TIme addition.PNGI can get the dt component of the waveform but I cannot get the right elapsed time in my .csv right.  It only writes a value of 1 for every time value in the column.


dt is a fixed value (time between samples). You have the start time(t0), dt and n samples so to get your sample time you must do <t0> + <dt>*<n>

______________________________________________________________
Have a pleasant day and be sure to learn Python for success and prosperity.
0 Kudos
Message 6 of 8
(35 Views)

There is a lot to be desired with that VI.

  • You are downloading a single point at a time
  • You have ever growing arrays
  • You never stop or clear the task

Here is a quick rewrite, you could still improve it.

 

snip.png

0 Kudos
Message 7 of 8
(25 Views)

Should have tested first. See mod, need a sequence structure with dialog.

 

snip.png

0 Kudos
Message 8 of 8
(10 Views)