Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Analog I/O synchronization with USB 6259

Dear members,
 
My problem now is to achieve a fast output response when an input signal is given. Explicitely the vi I attached is a simple program which gives in output what is given in input.
The problem is that output response is delayed at least 15 ms respect to the input .
This makes the PID regulator I implemented working at fastest 40 Hz.
The  problem is that Hardware sampling mode is not available on USB devices.
Has anyone an idea how fast could one go with a USB card and how to synchronize at best the two signals?
I would stress the fact that working with regeneration on is not feasible for a PID regulator.
 
Bye
 
Principiant
0 Kudos
Message 1 of 3
(3,455 Views)
 

Dear Principiant,

PID control with an USB device is quite some task... Depending on the algorhythm used, you might make it up to loop frequencies of maybe 100Hz, but you will still have a input to output latency of 10msec, as your control will always be one sample set ahead of the actual output.

I have attached an optimized VI, which runs steadily with 100Hz on my PC (2,3GHz single-core) and an USB-6259.

If this iteration time is still to slow, you might consider using an FPGA-based control design, offering PID loops up to 200kHz. If a PCI card is an option, you might consider NI's R-Series:

Multifunction R Series Intelligent DAQ Devices
https://www.ni.com/en-us/shop/category/multifunction-io.html?page=1&productId=118757&productId=11869...

If you would prefer to stick to USB, then CompactRIO might be your solution:

CompactRIO
https://www.ni.com/en/shop/compactrio.html

Best regards,
Sebastian

Message Edited by SFK on 03-10-2008 08:30 PM

0 Kudos
Message 2 of 3
(3,430 Views)

Hi SFK,

Many thanks for your help.

Unfortunately it seems the improved program you made works not so good on my setup , even worst of my program for some unknown reasons.

I have a Pentium 4 dual 3 Ghz ,1 Gb Ram but with your modification the maximum sampling I achieved is 100 Hz placing 10 sample per channel.

When I try to push up an error appears sayng that for some reason the resources of the Computer are not enough and some data are lost.

And with this sampling rate remains a delay of 100ms! (I use to test pulses at 0,5 Hz, 10 ms width).

With the previous program I am still able to reach 1000 Hz sampling and delay of 20 ms.

Anyway following your suggestions I already ordered a PCI card of M series (the 6989). Some people say me that he was able to run a PID 25 KHz which would be more than enough for me.

Bye

Principiant

 

0 Kudos
Message 3 of 3
(3,382 Views)