LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Low sampling rate issue

 

Hi everyone,

I’m currently working on a LabVIEW project to acquire pressure data using:

  • Sensor: PN2271 pressure sensor (4–20 mA analog output)

  • DAQ: NI 9146 Crio and 9203 module

I’ve built a VI  to acquire sensor data using the DAQ Assistant, but I’m only getting 10–12 readings per second. I want to achieve a much higher sampling rate, closer to the potential.

What I'm Doing:

  • Iam using TDMS logging

Request

  • Please help me understand how to modify or restructure my VI to:

    • Improve sampling rate

    • Correct any bad practices

    • Implement DAQmx properly

0 Kudos
Message 1 of 5
(361 Views)

Please spend the time to learn LabVIEW.  You need to learn DAQmx and learn to not use the DAQ Assistant (I call it the "Dreaded DAQ Assistant", or DDA, for short).

 

It is difficult to understand code from poor pictures (.pngs are much preferred to .jpegs) -- LabVIEW Projects, preferably "saved for previous version" to LabVIEW 2019 or 2021.  Among other things, seeing your code can help us suggest what you need to learn.

 

Bob Schor

 

 

0 Kudos
Message 2 of 5
(288 Views)

Please start with the Current - Continuous Input example, it will showcase how to use the DAQmx APIs to collect continuous data along with TDMS logging.

santo_13_2-1749522976916.png

 

santo_13_1-1749522963296.png

 

 

 

santo_13_0-1749522876230.png

 

Santhosh
Soliton Technologies

New to the forum? Please read community guidelines and how to ask smart questions

Only two ways to appreciate someone who spent their free time to reply/answer your question - give them Kudos or mark their reply as the answer/solution.

Finding it hard to source NI hardware? Try NI Trading Post
Message 3 of 5
(282 Views)

So there is one thing wrong in your description, your are NOT using any DAQ Assistant or DAQmx. 

 

You have setup a timed while loop with a loop periode of 100 ms, and in that while loop you are taking one sample from a Scan Engine variable and logging that to a tdms file.

So why are you only getting 10 sample a second? 

If you need a fast sampling, you need a faster loop time. 

And you need the Scan Engine time to match that, else you will get duplicates in your logging. 

 

 

0 Kudos
Message 4 of 5
(267 Views)

Hi mp,

 


@mp777 wrote:

 

I’m currently working on a LabVIEW project to acquire pressure data using:

  • DAQ: NI 9146 Crio and 9203 module

Request

  • Please help me understand how to modify or restructure my VI to:

    • Improve sampling rate

    • Correct any bad practices

    • Implement DAQmx properly


The NI9146 is a rather old Ethernet-based cRIO with a small FPGA inside.

It was designed before DAQmx got support for cRIO chassis, so your NI9146 isn't supported by DAQmx.

 

With those old cRIOs you have two options to read measurement data: ScanEngine or FPGA interface.

  • With ScanEngine you are rather limited regarding sample rate and channel count, but you may (try to) increase the sample rate to the low kS/s range with just one or two channels. As has been said: you need to configure the ScanEngine to your requirements!
  • Using the FPGA interface you get FULL control over the module options and can reach FULL sample rate as specified. There are example VIs/projects to handle modules in the FPGA and implement communication between FPGA and RT host…
    (I didn't work with your specific NI9146, so I cannot say much about the possibilities of the FPGA interface for this device.)

So what are your requirements specifically? (What is "much higher"?)

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 5 of 5
(259 Views)