04-20-2015 07:11 AM
Hello!
I am owning the cDAQ with the NI 9239 and NI 9263. (ADC and DAC).
I would like to do a succesive discrete concolution, i.e. I would like to do the fallowing process cyclic and continious:
1. get about 40 samples from ADC
2. do some calculation (for example a convolution)
3. send the result to the DAC
The problem is, that the responsetime for reading a sample from ADC and writing the sample directly back to DAC takes about 25ms (without any calculation). But the responsetime should be smaller than one ms.
Is there any way to decrese the responsetime?
Here are some details of my LabViewProject:
LabViewVersion: 2014
Using two DAQ-Assistants. One for reading from ADC, the other one for writing to DAC.
Both DAQ-Assistants are using continious-mode.
For testing the responsetime I connected the Dataoutput of the first Assistant directly with Datainput of the other one.
Both DAQ-Assistants are placed within a While-Loop.
Thank you very much!
04-20-2015 10:40 AM
1. Attach your code.
2. Do not use the DAQ assistants when looking for speed, they are slow.
3. If you are doing this on a Windows machine do not expect 1 ms accuracy. Not sure if you are looking for that or not.
4. It might also depend on if your cDAQ is ethernet or USB. They are not as fast as an internal PCIe card, it takes time to transfer data to/from the cDAQ.
5. Attach your code.
04-21-2015
04:27 AM
- last edited on
08-12-2024
05:54 PM
by
Content Cleaner
Hi eDeviser,
like Bryan already mentioned, it would be very helpful if you attach your code.
From my point of view, it will be difficult to reach your requirement of one ms response time.
The cDAQ platform is made for data aquisition and not for timing sensitive closed-loop control.
For closed-loop control NI offers a technology which is called Hardware-Timed Single Point.
More information about this technology is available in this whitepaper:
NI-DAQmx Hardware-Timed Single Point Lateness Checking - National Instruments
With a PXI system it is possible to reach more than 100k loop rate without much derivation.
Unfortunately, Hardware Timed Single Point is not available with your cDAQ.
Does My DAQ Device Support Hardware-Timed Single Point Sampling Mode?
Before you start to spend time to modify your existing code, you should think about the maximum allowed deviation of the one ms loop time. If your application requires a low deviation, you will not be able to build a reliable closed-loop control with a cDAQ. If you can accept a deviation of the loop time of some ms sometimes, you can try to optimize your code, so that it will speed up.
Best regards,
Peter