Hi,
I have a NI PCI-6251 device. I have created a counter input edge-count task. I receive the following error when I try to sample at 300,000Hz with an external clock:
Error -200141 occurred at DAQ Assistant
Possible Reason(s):
Data was overwritten before it could be read by the system.
If Data Transfer Mechanism is Interrupts, try using DMA or USB Bulk. Otherwise, divide the input signal before taking the measurement.
Providing an external clock from a function generator does not help resolve this. Sometimes I see this at 270,000Hz. My experiment was conducted on NI-Max. Here are the steps I followed:
1) Create a task. Select the "Acquire Signals" drop down, then under "Counter Input" select "Edge Count".
2) Select the NI PCI-6251 device.
3) In the configuration tab's Timing settings, set the Acquisition Mode to "Continuous Samples" and set the rate to 270k.
4) Click on the "Advanced Timing" tab.
5) Set the external clock source to the correct terminal.
6) Click "Run"
The error shows up in a pop up window. Please note that this experiment was performed on a real device and the behavior isn't reproducible on a simulated device.
Please let me know what is the correct setup to be able to count edges at rates such as 2MHz. Is is the upper limit on the sampling rate? If yes, what is the limit? Is there a NI-DAQmx function that I could use to find that number for a PCI device.
Thanks,
Varun Hariharan.
MathWorks