Real-Time Measurement and Control

Showing results for 
Search instead for 
Did you mean: 

NI-9252 read latency

Go to solution

I am intending to use a NI-9252 DAQ for real-time control of servo motors based on force inputs using a Linux OS in python. The servo motors do position holding using a very fast internal control loop, so I don't need to implement feedback control at the level of position holding itself. However, I still need low latency to avoid overall loss of performance in the system. About 1ms or less would be ideal.


For this reason I would like to know what the latency is (typically). Specifically, I am interested in knowing how long it would take for a change of state at the analog inputs to register as a change of state in the data stream sent to the computer. I intend to use a cDAQ-9171 hub so the latency will be at least 125 microseconds simply due to the USB 2.0 connection itself. However, I assume there will be further delays due to the various internal transfers of data that must occur between where the analog signal first arrives and where the digital and encoded signal is sent over the USB cable.

0 Kudos
Message 1 of 2
Accepted by topic author Sbollt

Using Python + USB + cDAQ is the worst combination for the latency. All of these contribute to latency significantly. 

If you want to use NI-9252 in Linux for the lowest latency, you should use a cDAQ controller (cDAQ-913x) or cRIO (cRIO-904x/5x is the best) with C programming or LabVIEW. For more details see Solved: How Can I tell what is the latency of NI USB-9263 using python and Re: Slow loop with cDaq 9174 but not with Ni6009.

0 Kudos
Message 2 of 2