LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Variable Rate DAQ Assistant

Solved!
Go to solution

How would you alter the rate of the DAQ assistant on the fly at certain time intervals then write them. I currently can get the rate to change going into the DAQ Assistant however when I pull the data it pulls over a 1000 points during the testing interval of 1 sec no matter what I do even if the rate input is between 1 and 5 Hz. Would this be a case where my hardware can only sample so slow and I need to manually in the code parse it down with something like average blocks of data in an inline statistics module?

PS: I started using Labview about 12 hours ago so if there are glaringly obvious fixes I would appreciate those as well.

 

Running on a cDAQ 9178 Chassis with a NI 9237 to bring in data from a load cell into Labview 2020 64-bit.

0 Kudos
Message 1 of 9
(2,690 Views)

Hi T1,

 


@T1p1ca1 wrote:

when I pull the data it pulls over a 1000 points during the testing interval of 1 sec no matter what I do even if the rate input is between 1 and 5 Hz.

Running on a cDAQ 9178 Chassis with a NI 9237 to bring in data from a load cell into Labview 2020 64-bit.


Please read the datasheet of your hardware first!

The NI9237 is somewhat special and limited in the supported samplerates! Samplerates of 1…5Hz aren't supported, that module will start at ~1600S/s…

 

On your VI:

Using DAQmx functions is rather easy after reading this (and learning from all those example VIs in the example finder). You really don't need the DAQAssistent…

 

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 9
(2,685 Views)

Even if I ultimately need to pull from 16 load cells for a month straight? The reason I went with the DAQ Assistant is that it can manage all those channels rather easily with different scales for each load cell. I may not have explained this correctly the first time I apologize

0 Kudos
Message 3 of 9
(2,663 Views)
Solution
Accepted by topic author T1p1ca1

Hi T1,

 


@T1p1ca1 wrote:

Even if I ultimately need to pull from 16 load cells for a month straight?


Especially in this case!

The DAQAssistent is fine for a short and quick test. For "professional" usage you should get rid of that ExpressVI very fast!

 


@T1p1ca1 wrote:

The reason I went with the DAQ Assistant is that it can manage all those channels rather easily with different scales for each load cell.


You can do so also very easily using plain DAQmx functions…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 9
(2,651 Views)

@T1p1ca1 wrote:

Even if I ultimately need to pull from 16 load cells for a month straight? The reason I went with the DAQ Assistant is that it can manage all those channels rather easily with different scales for each load cell. I may not have explained this correctly the first time I apologize


Especially if you need to pull from 16 load cells for a month straight. All of this is much more straight forward with DAQmx functions.

 

Edited to add: Looks like GerdW beat me to it.

0 Kudos
Message 5 of 9
(2,639 Views)

I am stuck using a NI 9237 to retrieve data from 16 load cells for a month. I need to lower the data acquisition rate to a more manageable level and change it on the fly from 50 to 1 to 0.000278. I was looking into changing the master time base to something slower since the spec sheet says that it's possible. Has anyone had luck doing this.

 

NI9237 - cDAQ9178 - Labview 2020 64-bit

0 Kudos
Message 6 of 9
(2,610 Views)

Hi T1,

 

I merged your threads because it's basically still the same problem…

 

Why don't you live with the supported sample rates of the NI9237 module?

I would:

  1. set a sample rate of 2500S/s
  2. read blocks of 500/625/833/1250/2500 samples and average them
  3. now you get values at 5/4/3/2/1 Hz, respectively!

Bonus: changing the number of samples to read "on the fly" is very easy, much easier than to change the samplerate of a DAQmx task…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 7 of 9
(2,597 Views)

The problem is that I don't know how to setup those blocks of data I would know how to set that up in DASYlab but not in Labview. Like I literally don't know where those modules or functions would be. That is actually what I was planning to do from the beginning but I didn't see a way to do it.

 

 

Edited: This file is where I'm at now after you telling me to use the DAQmx modules.

0 Kudos
Message 8 of 9
(2,592 Views)

Hi T1,

 

why don't you start with a simple VI? Learn step-by-step!

 

Set the "number of samples" as suggested before…

 

 

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 9 of 9
(2,584 Views)