Real-Time Measurement and Control

cancel
Showing results for 
Search instead for 
Did you mean: 

Best way to execute parallel operations

Hi to everyone!
From a very Labview beginner:
I'm using a NI CRIO and I need to read analogic signals at 5000 Hz from accelerometers with a Ni 9233 and, at the same time, 13 digital signals coming from an absolute encoder at 100000 Hz with a NI 9401. For the moment everything works in a big while loop in the fpga but I can't of course read the two different signals at their two different rates and, what I haven't understood yet, there's a some tenths of second delay in the display of the encoder position and speed on the real-time panel . According to the FPGA-getting started I should separate the two operations in two parallel loops and I do agree with it but what happens when I read the signals from the real-time VI? How can I set two separate reading rates? At this time I'm reading the data by simply reading from indicators on the fpga VI, is that a good way?I attached the fpga VI and the real-time VI to help you understand my problem. Could you please suggest me a way to make this system much faster?
I really thank you a lot in advance hoping to get an answer as soon as possible!!
 
Rob_F
 
Download All
0 Kudos
Message 1 of 2
(3,626 Views)

You should definitly use two different loops. How often do you need to update the values in the RT controller? If it is relativly slow then use a DMA fifo. If you need to read every value as it comes in then just use two different FPGA read nodes. If you aren't using DMA, you may want to consider syncronization by using IRQs, this will also implicitly set your reading rate as the update rate of the FPGA if you implement it correctly.

 

Jon

0 Kudos
Message 2 of 2
(2,905 Views)