Problem in ANSI C for example - error TDMS-ContAcq-IntClk 200877

Hello

I tried the examples in the 'ANSI C examples' folder and ran into a snag with the example in:

"" \DAQmx ANSI C\Analog In\Measure Voltage\Acq TDMS-Cont-Int Clk".

When I run it as it is, I get the following error:

DAQmx error: requested each interval of N samples event is not supported for the given the mechanism of transfer of data and the buffer size. To keep the DMA or USB in bulk as the data transfer mechanism, change the size of the buffer or the interval of event Every N samples so the size of the buffer is a multipleof even interval event Every N samples. To keep the same each event interval of N samples and the size of the buffer, modify the mechanism for transfer of data interruptions if taken in charge. Property: DAQmx_Every N samples CQI event IntervalRequested value buffer: size 1000Buffer: 12288Task name: _unnamedTask<0>State :-200877End of the program Code, press the Enter key to exit

As I was typing this, I did a quick test. I tried to comment this line in the code:

/ / * / / PDM DAQmx Configure Code / * / DAQmxErrChk (DAQmxConfigureLogging(taskHandle,"C:\\example.tdms",DAQmx_Val_LogAndRead,"GroupName",DAQmx_Val_OpenOrCreate));)

and it worked, as I suspected.

My gut feeling is that the DAQmxConfigureLogging function expects a block of 12 288 bytes, and in the rest of the code, the number of samples is set to 1000, with a sampling frequency of 10000.

In any case, I fixed it by changing from 1000 to 1024 (1024 because * 12 = 12288) anywhere in the code, so solve the original problem.

I don't have a few new questions now:

1. is this an error in the example, or am I missing something?

2. How do you change the default size 12288 DAQmxConfigureLogging() waiting for let say 5000?

Thank you.

Hall

Hey Bob,

In fact, it is a bug with this example.  It comes with the value 1000 for the wrong sampling interval since it is an example of logging.  When logging is enabled on a task, default buffer sizes are slightly different from the default values without connecting.  This is because the default buffer sizes are powers of 10, while hard drives prefer to powers of 2.  It is a maneuver of performance as we listen to disc directly from the buffer DAQmx.

I think you should be able to use 1024 as your sampling instead of 1000 interval in this example.  In this example, the default value will change so that it is not immediately error (Corrective Action Request #177199).

Tags: NI Software

Similar Questions

Maybe you are looking for

  • Apple Watch 42mm sport - Scribble

    Hi all I have question with my Apple Watch 42 mm sport - ios3 in and I use with iMessage Freehand drawing, but I can not Use scribble with Facebook Messenger. I have no no how I can use it. Thx for the help

  • HP Pavilion t3720 desktop PC: CPU upgrade

    Hello. I'm looking to upgrade the processor in my HP t3720.The motherboard is an A8M2N-(NodusM3) and the CPU processor is AMD Athlon 64 X 2 4200 +.What are the processors are compatible with this motherboard? I'm a bit confused because I read that so

  • keep a constant temperature

    Hi all Installation problem of &: I have a daq card that will measure the temperature of 6 thermocouples. I want that the average temperature of last 3 thermocouples to be as close as possible to the average temperature of the first 3 thermocouples.

  • Cannot install updates of security KB265639 - KB2686828

    I can not install updates of security for Net Framework Win XP x 86 KB265639 and KB2686828.  I have installed all updates, but these failed three times two, could you please help.  Thank you.

  • Whenever I reboot, I get a black screen saying Windows Vista running chkdsk

    After 10 attempt, I finally got vista on my laptop, I did a clean install, it crashes and I can not all service packs to install, its crashing, freezing,.., not all the time, but yesterday, he froze, I restarted and a black screen that says vista win