LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

DAQ Assistant - Error in DAQmx timing (sample clock)

Hi, I am getting an error while using DAQ Assistant. The error message is "the top-level vi was stopped at wire on the block diagram of daqmx timing (sample clock)". Even a simple DAQ assistant is not working. I am using NI USB 6341 and Labview version 2021. I have verified the version of DAQmx and repaired it and even installed it again. But nothing worked. Can you please suggest what would be the problem?

0 Kudos
Message 1 of 7
(1,390 Views)

@Arunr88 wrote:

Hi, I am getting an error while using DAQ Assistant. The error message is "the top-level vi was stopped at wire on the block diagram of daqmx timing (sample clock)". Even a simple DAQ assistant is not working. I am using NI USB 6341 and Labview version 2021. I have verified the version of DAQmx and repaired it and even installed it again. But nothing worked. Can you please suggest what would be the problem?


This is only a guess, but maybe the LabVIEW code you wrote has an error somewhere.  Perhaps if you posted your code, we could see if you "made a mistake".  I can't tell much from an error message (which doesn't make much sense to me, anyway).

 

Bob Schor

0 Kudos
Message 2 of 7
(1,378 Views)

Hi,

 

Thanks for your reply. Please find the attached code for your reference. But the issue is that, the error is showing not only for this specific code, but even for a simple VI with a DAQ asst is showing the same error.

0 Kudos
Message 3 of 7
(1,308 Views)

When you send someone a LabVIEW Project, you should ideally prepare your Project and the file containing the Project in the following way:

  1. Make sure you have a Folder that contains the LabVIEW Project file, as well as all of the VI's that you've written that are used in the Project.  If you use LabVIEW devices and toolkits, you don't need to include them, neither do you need to include common "library" files (such as things from vi.lib), nor Arduino stuff.
  2. Prepare a compressed Project folder by right-clicking the Project folder, "Send To:", "Compressed (zipped) Folder".  Most of us cannot open .rar files.

Please learn DAQmx, and stop using the Dreaded DAQ Assistant (a.k.a. DDA).  Read Learn 10 Functions in NI-DAQmx and Handle 80 Percent of Your Data Acquisition Applications and ignore the first Chapter.  You can also take a look at the DAQmx examples that ship with LabVIEW.

 

If you want to try again to attach a proper (and complete) Project Folder (zipped), we'll (be able to) take a look at it.

 

Bob Schor

0 Kudos
Message 4 of 7
(1,298 Views)

Hi Bob,

 

Thank you for your reply. Please find the attached zip folder for the main and sub-VIs. As I posted earlier, the problem occurred not only in this code. If I put a simple DAQ asst block to acquire an analog voltage from a single channel is also shows the same error. I have also attached the screenshots of the error. The error is within the inbuilt sub vi named "DAQmx Timing (Sample Clock)"

Download All
0 Kudos
Message 5 of 7
(1,280 Views)

One of the problems with using the DDA (Dreaded DAQ Assistant) instead of learning how to use "10 functions in NI-DAQmx" to handle your Data Acquisition Applications (there's an excellent White Paper from NI that you really should read) is you don't learn how to use DAQmx and if you realy on the DDA, you are liable to "gang aft agley" (as the Scottish LabVIEW enthusiast Robert Burns once remarked).

 

I'm not sure, but I think the reason you are getting Errors from the DAQ Assistants is that there is no Task/Device defined for them,  Had you used the DAQmx functions, and (as the White Paper should show you) wired a constant (which becomes a Task/Channel constant as appropriate) into the first DAQmx function in your chain, and then connected it to your DAQ device by simply clicking on the little downward-pointing Selection triangle, it would open to show available Input devices, and you could select the appropriate one and have the error disappear.  Or leave it blank and have an error "No device".

 

Hmm -- I'm sitting in an airport, and trying to generate a simple example, but LabVIEW isn't cooperating -- it keeps hanging.  So I can't gin up a simple demo, and have to go back and say "Look at the NI-DAQmx Timing" section of "Learn 10 functions" (or the DAQmx examples that ship with LabVIEW).  Note that the Examples (and, to a certain extent, the "Learn 10 Functions" document) show you a lot more than you need to wire/connect.  The key is that if your device is hooked into the PC, and you wire a Task Constant in to the Task/Channel input, when you right-click the Constant, it should expand and show you all the devices it "sees" and let you choose the one you want to use.  [I know, I said that in the previous paragraph ...].

 

Bob Schor

0 Kudos
Message 6 of 7
(1,266 Views)

Hi,

 

Thank you for the detailed reply. Meanwhile, I would like to inform you that the code was working fine before with DAQ Asst. Is there any chance for the corruption of DAQ asst library function in any case? Do you have any previous experience or noticed the same error that I mentioned in the screenshots? Because, I am not able to run any code in labview with this DAQ asst function.  

0 Kudos
Message 7 of 7
(1,241 Views)