LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

loop time versus frequency

Solved!
Go to solution

I attached a simple program with 2 ai and 2 ao's.  The acquisition rate is set to 1000Hz, but the loop running time is 2ms, when I'd expect it to be 1ms.  When I change the rate to 500, loop time goes up to 4ms, instead of 2ms.  What am I missing?

 

Maciek

0 Kudos
Message 1 of 2
(2,495 Views)
Solution
Accepted by topic author Maciekdp

(Sorry, I don't have DAQmx installed, so I cannot really look at the details of your code.)

 

In the upper task, you read twice per loop interation, once for position and once for force. Wouldn't once be enough?

 

Read once and just index both values out of the same 2D array at once. See if this makes a difference.

Message 2 of 2
(2,487 Views)