Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

General DAQ adquisition program, read and save in a file

dear all,

I am trying to do a general acquisition program with my HW DAQmx 9174 and my two targets NI 9229 and Ni9227. My idea is that a user has to choose the channels that he wants to read from 1channel current or voltage to 8 channels. After that I want to print it for screen, calculate the max and the minim values for each channel and at least save all data acquisition on a file.

 

My problem is that I think when in the reading while loop I put all the processing then it loose some data acquisition.

 

Has anyone an example of it? That acquire, process and save all the data in a file

 

Thank you,

Anna. 

0 Kudos
Message 1 of 9
(4,137 Views)

What kind of file format do you want?  I highly recommend using TDMS.  The reason is because there is a very handy little function in the DAQmx->Advanced palette.  It is called Configure Logging.  DAQmx has the capability of logging the data to disk without you having to worry about it.  It is a lot more efficient this way too since it bypasses the program level.

 

As far as the rest of what you are doing, I would recommend just having the reading of the DAQmx task in a loop on its own and use another loop to process the data.  Check out the Producer/Consumer for more details.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 2 of 9
(4,130 Views)

Thank you for the information. I've just been studying how to do that with TDMS and I don't know exactly how. Do you have any example of it? 

 

The program that I want, it is the user could select 4 channels to read voltage, and another’s 4 to read current. After that the program has to configure the DAQ acquisition, read the channels selected, print in the front panel, calculate the maximum, minimum and rms value, and save all the information on the file. 

More or less I have an example, however I don't know how to continue. Could you help me? In that example it is missed all the max, min and rms calculus. 

 

regards,

 

Anna. 

 

 

 

 

0 Kudos
Message 3 of 9
(4,116 Views)

Continued here:http://forums.ni.com/t5/LabVIEW/Select-different-devices-and-configuring-differents-properties/m-p/2...


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 4 of 9
(4,111 Views)

Hi,

the problem it is not only how to configure, unless it is in a while loop after DAQ read, I need to process data, I need to find the max, the min, and the rms, continuously, and after that calculate the power of each channel, all of them printed in a waveform graphic. 

 

So any example of it?

 

Anna. 

0 Kudos
Message 5 of 9
(4,093 Views)

Hi, I need help because I don't know how to focus the program. There are some form to do that but I’m stuck in the problem. I’ll try to explain what I want.

 

In that case the hardware that I have it is a cDAQ-9174, with two modules 9229 and 9227  (one analog input current, and the other analog input voltage). I want a general program where the user can choose, one or two or three or four channels and measure instant current and voltage, and I need to print the measure, and said which are the max, min and rms value for each channel. And at least calculate the power (P=VxI) for each channel and save all the information on a file. That it used to measure the voltage and current in different servo motors and generate a report of it.  

 

I’m really new with LV, and it is difficult to understand, TDMS, logging, queue, producer/consumer. I normally use a forum to solve my doubts, however I can’t find any completed example which can help me.  

 

I’ve  tested different forms, but none of it convince me.

 

1-     I have to user logging?

2-     How can I process the signal on the while loop without losing data.

3-     How storage all the information.

4-     I create voltage and current channel, after that time setting, can I use 1 time configuration for both(like the picture)?

 

 

I really need an example to understand how can I do all that I want.

 

Anna. 

0 Kudos
Message 6 of 9
(4,090 Views)

Hello, any help about it?

0 Kudos
Message 7 of 9
(4,077 Views)

Hi Everyone !!

 

 

I have coded on Labview 2011. I had to integrate my code with a old code written on labview 2008. But my new version was not oppening in 2008 (installed in my main system computer). So I upgrade the system labview version to 2011.

 

My system has 3 DAQ modules and in the application code there are several DAQ Assistants.

 

Now It seems that there is no information coming from DAQs in to the application. Is it because I need to reconfigure the DAQ assistant features through MAX?

 

But my whole program is running other elements are going well just no control and information on the DAQs.

 

Is there any one who  has this kind of experience??

 

Regards,

 

Hasan

0 Kudos
Message 8 of 9
(4,074 Views)

Hi, 

I really want to attach my program because I don't know how to continue. I don't know how can I use TDMS with two DAQmx Read. I need to calculate the instantaneous power of each channel, also the maximum and the minimum power, but I don't have enough knowlage to do that. I reacive the  error:

"Attempted to read samples that are not longer available....."

 

 

Download All
0 Kudos
Message 9 of 9
(4,034 Views)