FieldPoint Family

cancel
Showing results for 
Search instead for 
Did you mean: 

Way to acquire more than one sample at a time into Labview from cFP?

In reading data from my cFP into Labview I see that I can use the FP Read.vi but it only grabs one sample per call (loop iteration).  In other devices, I could just use the AI Acquire Waveform.vi to grab multiple samples per call.  Can I use this for cFP?  Is there another way to grab more than one sample per call from my cFP?  I'm just running it from a host computer, not using RT.
 
My specific problem is that I have two things I want to do with the same signal, one slow (PID control loop) and one fast (data logging).  If I put the FP Read.vi in the same loop as the PID control, I can only get one sample in the time it takes the PID loop to run which is too slow.  I'm trying to think of ways around this problem.
 
Thanks,
Hosehead
0 Kudos
Message 1 of 5
(4,159 Views)

Hello Hosehead,

With FieldPoint there is no way to acquire more than one same at a time like you can with NI-DAQ.  With the FieldPoint read and write VIs you can only read or write a single point at a time.

Please see the Sampling Speed of FieldPoint Modules document for more information on cFP acquisition rates.  This document explains how channels are updated, how often the data is updated, and what happens if you miss samples.  Please note that you will be able to acquire more samples if you are running your application on the RT controller and not on your host computer.

If this does not answer your question, can you please post more data about the rate you want your PID loop and your data logging loop to run at.

Regards,

Jesse O.
Applications Engineering
National Instruments

Jesse O. | National Instruments R&D
0 Kudos
Message 2 of 5
(4,133 Views)

Thanks Jesse.  This is helpful and answers my question.  I think I'll implement Master/Slave or maybe Producer/Consumer architecture in my Labview code as a way to solve this.

The benchmarking on the ftp site you linked seems only to be for FP 1000/1001 over RS232.  Do you know of a similar document for cFP modules using the cFP-2020 (or 20xx) over ethernet?

Not sure if it's still relevant but I'd like ~1 ms logging and 200 ms PID loop.  The 200 ms is something I got from a Labview example code so I'm flexible if you have other ideas there.

0 Kudos
Message 3 of 5
(4,133 Views)

Hello Hosehead,

I think Master/Slave or Producer/Consumer should work well for your application.

There isn't a benchmark document for our ethernet controllers because their performance is affected by network traffic so it is hard to provide a benchmark.

If you are using the AI-100, 110, or 112, your controller can run embedded much faster than the update rate of these modules.  As far as running on the host PC, you can run a simple VI to test how long it takes on average for you to get a new value for your system.  Depending on what analog input module you are using and if you are implementing any filtering, you may not be able to get a new value for logging every 1 ms. 

Please let us know if you have additional questions.

Regards,
Laura

0 Kudos
Message 4 of 5
(4,096 Views)

Jesse and Laura - Thanks for your help.  It's clearer now.

H.

0 Kudos
Message 5 of 5
(4,091 Views)