05-21-2013 06:33 AM
Maybe I'm completely off-topic...
but haven't you considered using a RIO device and its FPGA?
Regards,
Marco
...ops I just realized Clad19 had just suggested that...
05-21-2013 07:30 AM - edited 05-21-2013 07:36 AM
Hi Dominic:
(this post has been editted. I mixed up this one to my another discussion earlier.)
I see your point. I guess I need to get rid of USB, and use maybe something like PCI device.
Many thanks
Regards, Jhensi
05-21-2013 04:08 PM
A PCI device is going to have less latency than a USB device.
That being said, if you're running a non-deterministic OS like Windows then it's hard to cut down on your buffer too much since you might have a spike in latency and don't want to run out of data to generate (would result in an error).
One thing to keep in mind about the write call is that it blocks until all data has been written to the DAQmx buffer. If the buffer is still full of data to be generated, then the write call will block until the old data has been clocked out and the new data has been written in its place. If this is bothersome, you might consider using DAQmx events (every N Samples transferred from buffer) to only write new data when you know there is room for it in the buffer. By default, the buffer is the size of the first call to DAQmx Write (or you may instead configure the buffer size explicitly).
Best Regards,