LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to average data from DAQ Card?

Hi,

 

I am very new, in fact have not much experience with labview. I am currently doing my internship and have a great problem. I need to try solve this as fast as I could to avoid all the stress from my boss.

It would be nice if anyone could help me.

 

So I need a program, that read data from DAQ-Cards, it will collect all the values and average them after 60 minutes. This value, which had been average should be saved in a text file. This program should run for at least a day.

 

How to acquire the data from the cards won't be a problem for me. But how to collect them and average them in an hour is a big trouble. Any Help would be appreciated

0 Kudos
Message 1 of 6
(2,754 Views)

Use a shift register where you add each measurement to the existing data with each iteration. At the end, divide by the number of acquisitions to get the average.

(here's an example for averaging a single scalar, but it would be the same for an array of data)

 

What datatype is your acquired data? Can you attach a simplified example?

0 Kudos
Message 2 of 6
(2,751 Views)

Thanks...

 

But how do I save them every 60 minutes?

I am using a NI-USB 6008 card. The problem is I have no Labview at home, only at work, and at work I do not have Internet access. This task is really killing me. I can't get it out.

0 Kudos
Message 3 of 6
(2,746 Views)

Each time through your loop compare the current time to the previous time data was saved.  When the difference is >= 60 minutes, save the data and reset the previous save time to the current time.  This will require a shift register to kepp track of the previous time and a case structure for the save.

 

Lynn

0 Kudos
Message 4 of 6
(2,732 Views)

or you could just use the Elapsed Time Express VI.

0 Kudos
Message 5 of 6
(2,728 Views)

Am still very confused. Like I said, I am very new to this program, in fact I never used it before or learn it. Can anyone give me an example how it should look like?

I really appreciate what you all done.

0 Kudos
Message 6 of 6
(2,722 Views)