LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Using two FIFOs for two analog module

Hello,

I am working with NI-cRIO 9014 with NI-9104 chassis. I am trying to get analog data with NI-9219 and NI 9229. I am using windows 7 and LabVIEW 2017.

I want to use both modules together to get real-time data from different sensors. I have created the following FPGA program for the modules. The problem is I am getting data from the first FIFO for 9229 but no data from the second FIFO for 9219. Am I facing this problem due to 2 separate FIFO? or I need to use one loop for both modules?

 

It would be very kind if anyone can provide me a solution.

 

Best Regards,

Nisatuz Jahra

 

0 Kudos
Message 1 of 5
(1,651 Views)

In principle there's no problem using multiple FIFOs (up to the limit of your hardware, certainly more than 2) or multiple receiving loops (but probably no more than one per FIFO, or else you'll have to figure out how the data is being shared between the loops - probably not a good plan).

 

Here, your top loop is I believe adapted from an example? And uses a read with 0 elements to find the number of samples that can be read, and then reads full blocks of 4 elements (I guess channels of data?).

The bottom loop might be timing out some of the time, depending on the sample rate feeding the FIFO.

 

Also, this is an RT VI - can you show the FPGA VI too?


GCentral
0 Kudos
Message 2 of 5
(1,644 Views)

Hello,

 

Thank you for your reply. yes,  top loop is  adapted from an example. and it reads data from 4 channel. I am attaching the FPGA VI as you recommended. If i have created the program in a wrong way , then please suggest me how will i create a program that can take reading from all channels of two modules.we are connecting multiple sensors such as flow, pressure, force, torque with the modules.

 

Best Regards,

Nisatuz Jahra.

Download All
0 Kudos
Message 3 of 5
(1,574 Views)

Hello,

I am working with NI-cRIO 9014 with NI-9104 chassis. I am trying to get analog data with NI-9219 and NI 9229. I am using windows 7 and LabVIEW 2017.

I want to use both modules together to get real-time data from different sensors. I have created the following FPGA program for the modules. The problem is I am getting data from the first FIFO for 9229 but no data from the second FIFO for 9219. Am I facing this problem due to 2 separate FIFO? or I need to use one loop for both modules?

 

top loop is  adapted from an example. and it reads data from 4 channel. If i have created the program in a wrong way , then please suggest me how will i create a program that can take reading from all channels of two modules.we are connecting multiple sensors such as flow, pressure, force, torque with the modules.

 

It would be very kind if anyone can provide me a solution.

 

Best Regards,

Nisatuz Jahra

Download All
0 Kudos
Message 4 of 5
(1,597 Views)

Hello,

 

I have got the solution. I kept the number of elements and timeout same and i started to get data from both of the modules parallel. Just one problem arises that, after the data length is different for the modules.NI 9229 is having small length of data even the data rate is kept (max) 50.000 kS/s. I have added screenshot. Any solution for that?

 

Download All
0 Kudos
Message 5 of 5
(1,560 Views)