From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

NI Error 213706 on calling DAQmxCfgSampClkTiming

Hi,

 

I have an application that is reading data from an analog input channel on a NI PCIe 6363. The application reads a single sample and then tries to configure the sample clock timing to read a number of samples. I notice error -213706 when I execute DAQmxCfgSampClkTiming. The DAQmxGetExtendedErrorInfo method is not able to retrieve any information for this error code. I am using NI-DAQmx 15.5.0f1

 

I have attached my C code. Is this a bug? Can you provide a CAR number that I could use to track this.

 

I noticed a post related to this in the following link and wanted to know if it is related and if the CAR number (252982) present on that post has been addressed:

http://forums.ni.com/t5/Multifunction-DAQ/DAQmxStartTask-returns-error-code-213706-using-NI-DAQmx-9-...

 

 

Thanks,

Varun Hariharan.

0 Kudos
Message 1 of 5
(3,776 Views)

Hi Varun, 

 

It looks as though the CAR in post you referenced was fixed in DAQmx 9.4, but the error does seem similar. Could you attach the smallest reproducable version of the code and explain the steps you had to take to get the error?

 

Also have you looked at this forum post? It talks more about why this error may be occuring. Are the steps they talked about relevant to your issue? 

 

Export and import sample clock on cDAQ-9188 in C#

http://forums.ni.com/t5/Measurement-Studio-for-NET/Export-and-import-sample-clock-on-cDAQ-9188-in-C/...

Regards,

Jake H
Applications Engineer
0 Kudos
Message 2 of 5
(3,746 Views)

Hi Jake,

 

My original post does have the smallest reproducable version of the code. 

I look a look at the thread that you had linked in your post. I am not sure if this is the problem. The thread talks about properties that are not being set before calling DAQmxCfgSampClkTiming. 

 

After more debugging, I think this might be happening because I commit the task. Please let me know if you have any further thoughts. 

 

Regards,

Varun Hariharan.

0 Kudos
Message 3 of 5
(3,670 Views)

Hi Varun,

 

I think that you may be right about the TaskControl being the issue. Have you tried commenting out that portion of the code? Does this resolve the issue? 

 

I have included some links to the DAQmx Task State Model and DAQmx with Text-based programming. 

 

Using NI-DAQmx in Text Based Programming Environments

http://www.ni.com/tutorial/5409/en/

 

Task State Model

http://zone.ni.com/reference/en-XX/help/370466AC-01/mxcncpts/taskstatemodel/

 

Regards,

Jake H
Applications Engineer
0 Kudos
Message 4 of 5
(3,654 Views)

I know this is an old thread but I'm getting the same error, and I think I can suggest a fix to others. I'm using LabVIEW and am calling the "Configure sample clock timing" function, which is throwing this error. Returning an undefined error code isn't very helpful- the only two Google results are this post and the one the OP linked in the first post.

 

The problem seems to be that, in my case at least, I'd already transitioned the task to Reserved (for unrelated reasons) then tried to Export my sample clock to a PFI pin that I previously hadn't reserved. By Unreserving the task before calling my Configure Sample Clock, everything works as it should. I'd transitioned the whole thing to Reserved as I didn't need to actually start *using* the ports, but I did need to see if they were *available* to use.

Message 5 of 5
(2,463 Views)