LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Two Parallel Loops in RealTime

Hi,

I am using DAQmx with RT7.1 and DAQ Driver 7.2. I am running two loops in parallel. One loop will acquire data for 500 microSec and send the data to the other loop through Notifier. It will sleep for next 500MicroSec. For sleeping I am using Real time wait function. This loop is running in high priority. Other loop will wait for the Notifier and after receiving Notifier it will start its execution. This is running in normal priority mode. Now the problem is I am not getting the Notifier as soon as Daq-loop completes its acquisition. I am getting it after 500 or 1500 Micro seconds. I tried with RTFIFO also but same thing is happening. How to correct this?

Thanks,
S.Venkat
0 Kudos
Message 1 of 3
(2,989 Views)
The data you write to the RT FIFO is available immediately after RTFIFO Write.vi completes. You don't have to wait 500 to 1500 microseconds to read it. Just call RTFIFO Read.vi in the normal priority loop.

If the normal priority loop doesn't get the data right away, that's OK...it's a normal priority loop which means it can be preempted by just about everything. If that's not OK, then I'd have to ask why are you sending the data to a normal priority loop in the first place?
Message 2 of 3
(2,989 Views)
The world is right again!

Thank you!

Ben
Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 3 of 3
(2,989 Views)